From ba61d6282e4cfd2c3e299ea930de48fae48e3e97 Mon Sep 17 00:00:00 2001 From: cxl Date: Sun, 29 Nov 2020 14:59:03 +0000 Subject: [PATCH] .autotest, upphub.root git-svn-id: svn://ultimatepp.org/upp/trunk@15542 f0d560ea-af0d-0410-9eb7-867de7ffcac7 --- autotest/Heap/Heap.cpp | 17 ++++++++++------- .../ThreadExitAllocator/ThreadExitAllocator.cpp | 10 +++------- upphub.root | 14 ++++++++++++++ 3 files changed, 27 insertions(+), 14 deletions(-) create mode 100644 upphub.root diff --git a/autotest/Heap/Heap.cpp b/autotest/Heap/Heap.cpp index cddf7abf2..b68b0c5d4 100644 --- a/autotest/Heap/Heap.cpp +++ b/autotest/Heap/Heap.cpp @@ -138,13 +138,16 @@ CONSOLE_APP_MAIN StdLogSetup(LOG_FILE|LOG_COUT); TimeStop tm; - LOG("Allocator test:"); - HeapTest(256, 100000, true); - LOG("Checked allocator test Passed"); - HeapTest(8192, 1000000, false); - LOG("Quick allocator test Passed"); - HeapTest(8192, 100 * 1000000, false); - LOG("Allocator test Passed"); + for(int pass = 0; pass < 2; pass++) { + LOG("Allocator test:"); + HeapTest(256, 100000, true); + LOG("Checked allocator test Passed"); + HeapTest(8192, 1000000, false); + LOG("Quick allocator test Passed"); + HeapTest(8192, 100 * 1000000, false); + LOG("Allocator test Passed"); + MemoryFreeThread(); + } LOG("Used: " << MemoryUsedKb() << " KB"); LOG("============== OK " << tm); } diff --git a/autotest/ThreadExitAllocator/ThreadExitAllocator.cpp b/autotest/ThreadExitAllocator/ThreadExitAllocator.cpp index b6a58b9d8..115f75b7f 100644 --- a/autotest/ThreadExitAllocator/ThreadExitAllocator.cpp +++ b/autotest/ThreadExitAllocator/ThreadExitAllocator.cpp @@ -2,18 +2,14 @@ using namespace Upp; -struct Foo { - const char *text; - Foo(const char *text) : text(text) { LOG("Foo: " << text); } - ~Foo() { LOG("~Foo: " << text); } -}; +String text; CONSOLE_APP_MAIN { Thread t; t.Run([] { - thread_local Foo foo("local in Thread"); - LOG("In the thread"); + text = "This is just a test of thread shutdown"; }); t.Wait(); + DDUMP(text); } diff --git a/upphub.root b/upphub.root new file mode 100644 index 000000000..65cbd77ce --- /dev/null +++ b/upphub.root @@ -0,0 +1,14 @@ +UPPIVERSE_BEGIN +{ + "nests": [ + { "name": "URR", + "packages": [ "Urr" ], + "description": "Simple UDP Request-Response protocol", + "repository": "git@github.com:mirek-fidler/urr.git" + } + ], + "links": [ + "https://www.ultimatepp.org/forums/index.php?t=msg&th=11264&start=0&" + ] +} +UPPIVERSE_END