Skip to content

Commit 72b065b

Browse files
author
Arto Kinnunen
authored
Merge pull request #2133 from ARMmbed/few_updates
Adjust GC thresholds and unittests
2 parents 26166d1 + 1da0b9f commit 72b065b

File tree

3 files changed

+11
-17
lines changed

3 files changed

+11
-17
lines changed

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ $(TESTDIRS):
6565

6666
$(CLEANTESTDIRS):
6767
@make -C $(@:clean-%=%) clean
68+
@rm -fr results
6869

6970
.PHONY: release
7071
release:

source/Core/ns_monitor.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ typedef enum {
4242
NS_MONITOR_STATE_GC_CRITICAL
4343
} ns_monitor_state_e;
4444

45-
#define HEAP_HIGH_WATERWARK (0.80) /* Heap usage HIGH threshold */
46-
#define HEAP_CRITICAL_WATERMARK (0.90) /* Heap usage CRITICAL threshold */
45+
#define HEAP_HIGH_WATERWARK (0.95) /* Heap usage HIGH threshold */
46+
#define HEAP_CRITICAL_WATERMARK (0.99) /* Heap usage CRITICAL threshold */
4747

4848
#define NS_MAINTENANCE_TIMER_INTERVAL 10 // Maintenance interval
4949

@@ -144,7 +144,6 @@ int ns_monitor_init(void)
144144
ns_monitor_ptr->ns_monitor_heap_gc_state = NS_MONITOR_STATE_HEAP_GC_IDLE;
145145
ns_monitor_ptr->ns_maintenance_timer = 0;
146146
ns_monitor_ptr->prev_heap_alloc_fail_cnt = 0;
147-
tr_debug("Monitor init high:%lu, critical:%lu total:%lu", (unsigned long)ns_monitor_ptr->heap_high_watermark, (unsigned long)ns_monitor_ptr->heap_critical_watermark, (unsigned long)ns_monitor_ptr->mem_stats->heap_sector_size);
148147
return 0;
149148
}
150149

test/nanostack/unittest/thread/nvm/Makefile

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,13 @@ TEST_SRC_FILES = \
1717

1818
include ../../MakefileWorker.mk
1919

20-
CLEAN-DIRS := $(foreach dir,$(DIRS),clean-$(dir))
21-
clean: $(CLEAN-DIRS)
22-
rm -rf stub/*gcov stub/*gcda stubs/*o
23-
rm -rf results/*
24-
rm -rf coverages/*
25-
rm -rf results
26-
rm -rf coverages
27-
rm -rf lib/*
28-
rm -rf objs/*
29-
rm -f /tmp/fd.txt
20+
clean:
21+
rm -f f_d
22+
rm -f s_d
23+
rm -f cpputest_thread_nvm_store.xml
24+
rm -f thread_nvm_store_unit_tests
25+
rm -f thread_nvm_store_unit_tests
26+
rm -f thread_nvm_store_unit_tests.txt
3027

31-
.PHONY: $(CLEAN-DIRS)
32-
$(CLEAN-DIRS):
33-
make -C $(subst clean-,,$@) clean
28+
CPPUTESTFLAGS += -DFEA_TRACE_SUPPORT -DHAVE_THREAD
3429

35-
CPPUTESTFLAGS += -DFEA_TRACE_SUPPORT -DHAVE_THREAD=1

0 commit comments

Comments
 (0)