Skip to content
This repository has been archived by the owner on Nov 9, 2022. It is now read-only.

E2k support #91

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,17 @@ MESSAGE(STATUS "FTL DISABLE_FTL_APP: " ${DISABLE_FTL_APP})
option(FTL_STATIC_COMPILE "Set to TRUE if you want ftl to be compiled as a static lib. If TRUE, the program will want to statically link to the ftl cmake object." FALSE)
MESSAGE(STATUS "FTL FTL_STATIC_COMPILE: " ${FTL_STATIC_COMPILE})

include(CheckCCompilerFlag)

if(LOWERCASE_CMAKE_SYSTEM_PROCESSOR MATCHES "e2k")
foreach(TEST_C_FLAG "-Wno-unused-parameter" "-Wno-pointer-sign" "-Wno-unused-variable" "-Wno-sign-compare" "-Wno-maybe-uninitialized")
CHECK_C_COMPILER_FLAG(${TEST_C_FLAG} C_COMPILER_SUPPORTS_FLAG_${TEST_C_FLAG})
if(C_COMPILER_SUPPORTS_FLAG_${TEST_C_FLAG})
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${TEST_C_FLAG}")
endif()
endforeach()
endif()

find_package(Threads REQUIRED)

set (CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
Expand Down
1 change: 1 addition & 0 deletions ftl_app/bitstream.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "dec_obj.h"
#include "utils.h"
#include "bitstream.h"

Expand Down
4 changes: 3 additions & 1 deletion ftl_app/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
* SOFTWARE.
**/

#include "ftl.h"
#include "main.h"
#include "gettimeofday.h"
#ifdef _WIN32
Expand All @@ -34,6 +35,7 @@
#include <pthread.h>
#include <sys/time.h>
#endif
#include <string.h>
#include "file_parser.h"

void sleep_ms(int ms)
Expand Down Expand Up @@ -425,7 +427,7 @@ static void *ftl_status_thread(void *data)
{
ftl_packet_stats_msg_t *p = &status.msg.pkt_stats;

printf("Avg packet send per second %3.1f, total nack requests %d\n",
printf("Avg packet send per second %3.1f, total nack requests %ld\n",
(float)p->sent * 1000.f / p->period,
p->nack_reqs);
}
Expand Down
2 changes: 1 addition & 1 deletion libftl/ftl_private.h
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ typedef struct _ftl_ingest_t {
typedef struct
{
ftl_handle_t* handle;
BOOL(*change_bitrate_callback)(void*, uint64_t);
int(*change_bitrate_callback)(void*, uint64_t);
void* context;
uint64_t initial_encoding_bitrate;
uint64_t max_encoding_bitrate;
Expand Down
2 changes: 1 addition & 1 deletion libftl/ingest.c
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ OS_THREAD_ROUTINE _ingest_get_hosts(ftl_stream_configuration_private_t *ftl) {

ftl->ingest_count = total_ingest_cnt;

return total_ingest_cnt;
return (OS_THREAD_ROUTINE)total_ingest_cnt;
}

char * ingest_find_best(ftl_stream_configuration_private_t *ftl) {
Expand Down