mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-22 10:30:13 +00:00
added %.ramprof and %.flashprof targets for easy memory profiling of linked binary (e.g. make hello-world.ramprof)
This commit is contained in:
parent
63ea562568
commit
10b4105200
@ -228,6 +228,12 @@ ifndef CUSTOM_RULE_LINK
|
|||||||
$(LD) $(LDFLAGS) $(TARGET_STARTFILES) ${filter-out %.a,$^} ${filter %.a,$^} $(TARGET_LIBFILES) -o $@
|
$(LD) $(LDFLAGS) $(TARGET_STARTFILES) ${filter-out %.a,$^} ${filter %.a,$^} $(TARGET_LIBFILES) -o $@
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
%.ramprof: %.$(TARGET)
|
||||||
|
nm -S -td --size-sort $< | grep -i " [abdrw] " | cut -d' ' -f2,4
|
||||||
|
|
||||||
|
%.flashprof: %.$(TARGET)
|
||||||
|
nm -S -td --size-sort $< | grep -i " [t] " | cut -d' ' -f2,4
|
||||||
|
|
||||||
# Don't treat %.$(TARGET) as an intermediate file because it is
|
# Don't treat %.$(TARGET) as an intermediate file because it is
|
||||||
# in fact the primary target.
|
# in fact the primary target.
|
||||||
.PRECIOUS: %.$(TARGET)
|
.PRECIOUS: %.$(TARGET)
|
||||||
|
Loading…
Reference in New Issue
Block a user