mirror of
https://github.com/bkaradzic/bx.git
synced 2026-02-17 20:52:37 +01:00
Cleanup.
This commit is contained in:
@@ -941,7 +941,7 @@ function toolchain(_buildDir, _libDir)
|
||||
}
|
||||
|
||||
linkoptions {
|
||||
"-s MAX_WEBGL_VERSION=2"
|
||||
"-s MAX_WEBGL_VERSION=2",
|
||||
}
|
||||
|
||||
configuration { "wasm2js" }
|
||||
@@ -949,7 +949,7 @@ function toolchain(_buildDir, _libDir)
|
||||
objdir (path.join(_buildDir, "wasm2js/obj"))
|
||||
libdirs { path.join(_libDir, "lib/wasm2js") }
|
||||
linkoptions {
|
||||
"-s WASM=0"
|
||||
"-s WASM=0",
|
||||
}
|
||||
|
||||
configuration { "wasm" }
|
||||
|
||||
@@ -14,15 +14,19 @@ TEST_CASE("getProcessMemoryUsed", "")
|
||||
// DBG("bx::getProcessMemoryUsed %d", bx::getProcessMemoryUsed() );
|
||||
}
|
||||
|
||||
#if BX_CONFIG_SUPPORTS_THREADING
|
||||
|
||||
TEST_CASE("semaphore_timeout", "")
|
||||
{
|
||||
bx::Semaphore sem;
|
||||
|
||||
int64_t start = bx::getHPCounter();
|
||||
bool ok = sem.wait(900);
|
||||
int64_t elapsed = bx::getHPCounter() - start;
|
||||
int64_t start = bx::getHPCounter();
|
||||
bool ok = sem.wait(900);
|
||||
int64_t elapsed = bx::getHPCounter() - start;
|
||||
int64_t frequency = bx::getHPFrequency();
|
||||
double ms = double(elapsed) / double(frequency) * 1000;
|
||||
printf("%f\n", ms);
|
||||
double ms = double(elapsed) / double(frequency) * 1000;
|
||||
bx::printf("%f\n", ms);
|
||||
REQUIRE(!ok);
|
||||
}
|
||||
|
||||
#endif // BX_CONFIG_SUPPORTS_THREADING
|
||||
|
||||
@@ -6,6 +6,8 @@
|
||||
#include "test.h"
|
||||
#include <bx/thread.h>
|
||||
|
||||
#if BX_CONFIG_SUPPORTS_THREADING
|
||||
|
||||
bx::DefaultAllocator s_allocator;
|
||||
bx::MpScUnboundedBlockingQueue<void> s_mpsc(&s_allocator);
|
||||
|
||||
@@ -69,3 +71,5 @@ TEST_CASE("MpScUnboundedBlockingQueue", "")
|
||||
|
||||
REQUIRE(result == 0x1389);
|
||||
}
|
||||
|
||||
#endif // BX_CONFIG_SUPPORTS_THREADING
|
||||
|
||||
Reference in New Issue
Block a user