Jimmy Brisson
d6bee561ab
Squash weird import bug
2016-07-07 15:29:36 -05:00
Jimmy Brisson
0ec8199c55
Revert "Revert "Generalize flag handling""
...
This reverts commit 33cec194c6
.
2016-07-07 15:29:36 -05:00
Przemek Wirkus
12a01f61ca
Add summary for test building
...
When users are building tests with `mbed compile --tests` whey will by default
get memory map breakdown report.
This can be suppresed in the future with command line switch. For now it is
visible each time users build test cases.
List is sorted by project name created with `build_project` API.
Changes:
* `build_project` now returns tuple (this breaks build_api.build_project API!)
* Memmap script got a aggregation function to print summary from small 'JSON'
partial reports.
* Report is generated by `test_api.build_tests` function only!
Example:
```
+----------------------------------------------------------------------+--------+-----------+-------------+------------+-------+-------+-----------+
| name | target | toolchain | total_flash | static_ram | stack | heap | total_ram |
+----------------------------------------------------------------------+--------+-----------+-------------+------------+-------+-------+-----------+
| features-feature_ipv4-tests-mbedmicro-net-nist_internet_time_service | K64F | GCC_ARM | 132136 | 62288 | 32768 | 65536 | 160592 |
| features-feature_ipv4-tests-mbedmicro-net-tcp_client_echo | K64F | GCC_ARM | 125613 | 62448 | 32768 | 65540 | 160756 |
| features-feature_ipv4-tests-mbedmicro-net-tcp_client_hello_world | K64F | GCC_ARM | 125949 | 62448 | 32768 | 65540 | 160756 |
| features-feature_ipv4-tests-mbedmicro-net-udp_echo_client | K64F | GCC_ARM | 123613 | 62276 | 32768 | 65536 | 160580 |
| features-storage-tests-cfstore-add_del | K64F | GCC_ARM | 96080 | 13052 | 32768 | 65540 | 111360 |
| features-storage-tests-cfstore-close | K64F | GCC_ARM | 95520 | 12004 | 32768 | 65540 | 110312 |
| features-storage-tests-cfstore-create | K64F | GCC_ARM | 99144 | 13036 | 32768 | 65540 | 111344 |
| features-storage-tests-cfstore-example1 | K64F | GCC_ARM | 98592 | 12368 | 32768 | 65536 | 110672 |
| features-storage-tests-cfstore-example2 | K64F | GCC_ARM | 95232 | 12012 | 32768 | 65540 | 110320 |
| features-storage-tests-cfstore-example3 | K64F | GCC_ARM | 95264 | 11856 | 32768 | 65536 | 110160 |
| features-storage-tests-cfstore-example4 | K64F | GCC_ARM | 92632 | 12012 | 32768 | 65540 | 110320 |
| features-storage-tests-cfstore-example5 | K64F | GCC_ARM | 92344 | 11856 | 32768 | 65536 | 110160 |
| features-storage-tests-cfstore-find | K64F | GCC_ARM | 96344 | 13028 | 32768 | 65540 | 111336 |
| features-storage-tests-cfstore-find2 | K64F | GCC_ARM | 93192 | 12004 | 32768 | 65540 | 110312 |
| features-storage-tests-cfstore-flash | K64F | GCC_ARM | 97784 | 12532 | 32768 | 65540 | 110840 |
| features-storage-tests-cfstore-flush | K64F | GCC_ARM | 96464 | 12012 | 32768 | 65540 | 110320 |
| features-storage-tests-cfstore-flush2 | K64F | GCC_ARM | 95056 | 12004 | 32768 | 65540 | 110312 |
| features-storage-tests-cfstore-init | K64F | GCC_ARM | 93120 | 12012 | 32768 | 65540 | 110320 |
| features-storage-tests-cfstore-misc | K64F | GCC_ARM | 96808 | 12516 | 32768 | 65540 | 110824 |
| features-storage-tests-cfstore-open | K64F | GCC_ARM | 98632 | 12540 | 32768 | 65540 | 110848 |
| features-storage-tests-cfstore-read | K64F | GCC_ARM | 94112 | 12540 | 32768 | 65540 | 110848 |
| features-storage-tests-cfstore-write | K64F | GCC_ARM | 94488 | 12004 | 32768 | 65540 | 110312 |
| features-storage-tests-flash_journal-basicapi | K64F | GCC_ARM | 104712 | 21236 | 32768 | 65540 | 119544 |
| frameworks-utest-tests-unit_tests-basic_test | K64F | GCC_ARM | 71534 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-case_async_validate | K64F | GCC_ARM | 74598 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-case_control_async | K64F | GCC_ARM | 74630 | 11476 | 32768 | 65540 | 109784 |
| frameworks-utest-tests-unit_tests-case_control_repeat | K64F | GCC_ARM | 72790 | 11452 | 32768 | 65540 | 109760 |
| frameworks-utest-tests-unit_tests-case_selection | K64F | GCC_ARM | 72302 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-case_setup_failure | K64F | GCC_ARM | 72630 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-case_teardown_failure | K64F | GCC_ARM | 72790 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-control_type | K64F | GCC_ARM | 82462 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-minimal_async_scheduler | K64F | GCC_ARM | 72182 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-minimal_scheduler | K64F | GCC_ARM | 71998 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-test_assertion_failure_test_setup | K64F | GCC_ARM | 71710 | 11460 | 32768 | 65540 | 109768 |
| frameworks-utest-tests-unit_tests-test_setup_case_selection_failure | K64F | GCC_ARM | 71702 | 11468 | 32768 | 65540 | 109776 |
| frameworks-utest-tests-unit_tests-test_setup_failure | K64F | GCC_ARM | 71710 | 11468 | 32768 | 65540 | 109776 |
| tests-integration-basic | K64F | GCC_ARM | 67566 | 10780 | 32768 | 65540 | 109088 |
| tests-integration-threaded_blinky | K64F | GCC_ARM | 68326 | 10780 | 32768 | 65540 | 109088 |
| tests-mbed_drivers-c_strings | K64F | GCC_ARM | 74438 | 11468 | 32768 | 65540 | 109776 |
| tests-mbed_drivers-callback | K64F | GCC_ARM | 88310 | 11972 | 32768 | 65540 | 110280 |
| tests-mbed_drivers-dev_null | K64F | GCC_ARM | 90213 | 10784 | 32768 | 65540 | 109092 |
| tests-mbed_drivers-echo | K64F | GCC_ARM | 71918 | 11468 | 32768 | 65540 | 109776 |
| tests-mbed_drivers-generic_tests | K64F | GCC_ARM | 77624 | 11468 | 32768 | 65540 | 109776 |
| tests-mbed_drivers-rtc | K64F | GCC_ARM | 85854 | 11308 | 32768 | 65540 | 109616 |
| tests-mbed_drivers-stl_features | K64F | GCC_ARM | 80726 | 11476 | 32768 | 65540 | 109784 |
| tests-mbed_drivers-ticker | K64F | GCC_ARM | 70974 | 11308 | 32768 | 65540 | 109616 |
| tests-mbed_drivers-ticker_2 | K64F | GCC_ARM | 70790 | 11308 | 32768 | 65540 | 109616 |
| tests-mbed_drivers-ticker_3 | K64F | GCC_ARM | 71038 | 11308 | 32768 | 65540 | 109616 |
| tests-mbed_drivers-timeout | K64F | GCC_ARM | 70886 | 11308 | 32768 | 65540 | 109616 |
| tests-mbed_drivers-wait_us | K64F | GCC_ARM | 70414 | 11308 | 32768 | 65540 | 109616 |
| tests-mbedmicro-mbed-attributes | K64F | GCC_ARM | 71534 | 11460 | 32768 | 65540 | 109768 |
| tests-mbedmicro-mbed-call_before_main | K64F | GCC_ARM | 73112 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-mbed-cpp | K64F | GCC_ARM | 73400 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-mbed-div | K64F | GCC_ARM | 73176 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-rtos-mbed-basic | K64F | GCC_ARM | 68390 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-rtos-mbed-isr | K64F | GCC_ARM | 74480 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-rtos-mbed-mail | K64F | GCC_ARM | 74992 | 11300 | 32768 | 65540 | 109608 |
| tests-mbedmicro-rtos-mbed-mutex | K64F | GCC_ARM | 74048 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-rtos-mbed-queue | K64F | GCC_ARM | 74912 | 11300 | 32768 | 65540 | 109608 |
| tests-mbedmicro-rtos-mbed-semaphore | K64F | GCC_ARM | 74296 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-rtos-mbed-signals | K64F | GCC_ARM | 74328 | 10780 | 32768 | 65540 | 109088 |
| tests-mbedmicro-rtos-mbed-threads | K64F | GCC_ARM | 75214 | 11460 | 32768 | 65540 | 109768 |
| tests-mbedmicro-rtos-mbed-timer | K64F | GCC_ARM | 68430 | 10780 | 32768 | 65540 | 109088 |
| tests-storage_abstraction-basicapi | K64F | GCC_ARM | 107808 | 28908 | 32768 | 65540 | 127216 |
+----------------------------------------------------------------------+--------+-----------+-------------+------------+-------+-------+-----------+
```
Refactored after code review
Refactored parse() function
Polishing
Moved memory usage reporting function call to test.py to group all reporters in one place
Bug-fix: on ARM toolchain we were not fetching statistics from last element of memap result list
2016-07-07 08:35:20 +01:00
Sam Grove
458b46c803
Merge pull request #1873 from theotherjimmy/file-reporter
...
Adds a simple text file report format
2016-07-06 16:45:43 -05:00
Sam Grove
36ff1f73ce
Merge pull request #2106 from theotherjimmy/fix-makefile
...
[Exporter-gcc_arm] do builds from project directory when --source is specified
2016-07-06 15:33:28 -05:00
Jimmy Brisson
3697dedb78
Reverse order of relativizing paths and unixifing paths
...
'cause windows silly path separator is the same as the escape character
2016-07-06 13:54:33 -05:00
Jimmy Brisson
3cf8bfbfb7
Allow spaces in paths passed to mkdir and rm on bash
2016-07-06 12:51:14 -05:00
Jimmy Brisson
fbccf8dfc9
Force shell use when in bash/sh mode
2016-07-06 12:49:38 -05:00
Jimmy Brisson
c2d66865be
Correct batch detection algorimthm
...
There are two shell-like things that we care about
bash: does environment varible expansion with $
batch: does environment varible expansion by surrounding something with %
so to detect batch, try to expand a variable on the shell with $.
If you get a $ back, you are in batch!
2016-07-06 11:32:01 -05:00
Martin Kojtal
e237d157dd
Merge pull request #2113 from ohagendorf/gcc_export
...
[bugfix gcc_arm] build+make <-> export project+make: different results
2016-07-06 13:49:10 +01:00
Olaf Hagendorf
bd614a2a11
[bugfix gcc_arm] build+make <-> export project+make: different results
...
when in target.json "default_build": "small" is configured
- build.py+make.py
- uses linker option --specs=nano.specs
- macro MBED_RTOS_SINGLE_THREAD is defined
- exporting with project.py + make Makefile
- doesn't use the linker option --specs=nano.specs
- doesn't contain macro MBED_RTOS_SINGLE_THREAD
2016-07-06 13:35:09 +02:00
Olaf Hagendorf
7f2f0bc5c6
repairing a minor typo in exporters.py
2016-07-06 13:34:59 +02:00
Bogdan Marinescu
b8c64cd275
Merge pull request #2102 from mbedmicro/fix_tests_with_config
...
Fix tests with config
2016-07-06 11:09:20 +03:00
Jimmy Brisson
61ee30efb2
Fix normal export (no --source)
2016-07-05 12:04:36 -05:00
Jimmy Brisson
fa527cf45e
Rework vpaths and include file locating
2016-07-05 11:51:27 -05:00
Jimmy Brisson
4b7f591d33
Fix the makefile template
...
- Corrects a python barf when something in features is None
- Corrects makefile to prevent barf when using make -f
2016-07-05 10:16:50 -05:00
Bogdan Marinescu
fbb26a405c
Fix tests.py so it can work with application defined targets
...
With this patch in place, tests.py uses targets names instead of target
instances, which makes it possible to use application defined targets
with tests.
2016-07-05 15:52:53 +03:00
Bogdan Marinescu
36a577e1ef
Make build_tests work with target names, not just Target instances
...
With this change, custom targets defined by the application being
tested in its mbed_app.json file can be used with tests. Note that
`build_project` already accepts both target names and instances, so the
call to `build_project` inside `build_tests` will still work.
2016-07-05 15:47:26 +03:00
Bogdan Marinescu
e3d29fe5d2
Improve configuration handling in build_project
...
The configuration object is now created early in the build_project
function. This way, if there's a mbed_app.json that contains a custom
target, that target is taken into account. This is useful (for example)
when compiling tests for an application that defines a custom target.
2016-07-05 15:40:12 +03:00
0xc0170
3b84b42a53
Build release - use target.release to produce release tuple
2016-07-05 10:50:29 +01:00
Olaf Hagendorf
4fe41d4edd
fpu with single/double precision - removing redundancy
...
- removing redundancy as discussed in PR #2087 :
- in target.json the core option can have only this values : "Cortex-M0", "Cortex-M0+", "Cortex-M1", "Cortex-M3", "Cortex-M4", "Cortex-M7", "Cortex-A9" - Cortex-M4F and Cortex-M7F removed
- in target.json an additional fpu option with values: "single" and "double" can be used
- build and export scripts are changed to handle this
- tested (compiling, running on hardware) with nucleo_f767 (cortex-m7 with double precision fpu), nucleo_f746 (cortex-m7 with single precision fpu), nucleo_f446 and nucleo_l467 (cortex-m4 with single precision fpu), teensy31 (cortex-m4 without fpu - only build test), nucleo_l073 (cortex-m0)
- singletest results are added to PR #2087 comments
2016-07-04 22:08:31 +02:00
Olaf Hagendorf
ea196e2adb
fpu with single/double precision - bugfix and extension
...
- creating new core name Cortex_M7F_DP for a target with a double precision fpu
- adding new core name to arm.py to set compiler/linker flags to a double precision fpu when configured in target.json
- up to now: gcc wrote flag for a double precision fpu -> target with STM32F746 didn't run when using double variables - mcu has only single precision fpu
- changing gcc.py to use single precision for Cortex-M7 und double precision for Cortex_M7F_DP
tested with NUCLEO_F746, NUCLEO_F767 and build.py+make.py and exporting with project.py + compiling/flashing
- iar.py need a similar extention - I didn't change that yet because
- did not run at the moment - python exception
- currently worked on in PR #1948
2016-07-04 22:08:30 +02:00
Erwan GOURIOU
eaf77ed37f
[STM32F4xx][NUCLEO_F429ZI] Add on for NUCLEO_F429ZI export and tests
2016-07-04 15:20:12 +02:00
Erwan Gouriou
9bb08291ce
[STM32F4xx] Add support for NUCLEO_F429ZI
2016-07-04 14:00:41 +02:00
Laurent Meunier
4e1a3351b2
[NUCLEO_F446ZE] Add to build and export scripts
2016-07-04 11:44:28 +02:00
Olaf Hagendorf
4211f7581e
[NUCLEO_F7xx] adding F767 to build_release and adding default_build to target.json
2016-07-01 16:27:20 +02:00
ohagendorf
fdda915a8a
[NUCLEO_F767ZI] adding target to rtos lib
2016-07-01 15:19:30 +02:00
ohagendorf
9ddbb1f831
[NUCLEO_F767] move gcc template to new path
2016-07-01 15:17:25 +02:00
Olaf Hagendorf
3ac68aae06
typo in target names for travis build
2016-07-01 15:17:21 +02:00
ohagendorf
cc537f7449
adding gccarm and uvision5 exporter
2016-07-01 15:17:21 +02:00
Martin Kojtal
62604b45b2
Merge pull request #1880 from zgoda/generic_bluepill
...
Support for Blue Pill
2016-07-01 14:52:04 +02:00
Martin Kojtal
6350b2d904
Merge pull request #2046 from sarahmarshy/patch-2
...
Changed reference to old rtos location
2016-07-01 13:33:40 +02:00
Sam Grove
185676300d
Merge pull request #2060 from theotherjimmy/cleanup-make-export
...
[Exporters-gcc_arm] Clean up the source directory
2016-06-30 13:01:54 -05:00
Jimmy Brisson
3850c2628b
Force all to be the default target
2016-06-30 11:43:01 -05:00
Jimmy Brisson
6c1c7a5955
Check for OSTYPE instead of OS
...
It better detects sh vs. batch
2016-06-30 11:28:32 -05:00
Sam Grove
197c4b516b
Merge pull request #2076 from bridadan/relative-paths-test-spec
...
Relative paths in test spec file
2016-06-30 11:01:07 -05:00
Jimmy Brisson
d6d0202236
Move binaries from bin to .build
2016-06-30 10:55:34 -05:00
Jimmy Brisson
5d014661c2
Redo window mkdir; add cross-platform rmdir
2016-06-30 10:55:10 -05:00
Jimmy Brisson
6867499da3
Test for existance of dir before creating it
2016-06-30 10:55:04 -05:00
Jimmy Brisson
6971b1e1b4
update mkdir to be cross-platform
2016-06-30 10:51:19 -05:00
Jimmy Brisson
7b5831247d
Make the efm32 targets use the common makefile template
2016-06-30 10:51:19 -05:00
Jimmy Brisson
63f4e6a279
sam*::gcc_arm targets extend the common makefile
2016-06-30 10:51:19 -05:00
Jimmy Brisson
86585197da
rework the common template to place objects into bin
2016-06-30 10:51:18 -05:00
Brian Daniels
b7186bb604
Test spec paths are now relative to tool execution directory
...
This commit also normalizes the paths produced by the the test spec to
Unix style paths to increase portability of the file.
2016-06-30 09:32:13 -05:00
svastm
505814147d
[NUCLEO_L432KC] Add RTOS support
2016-06-30 15:05:09 +02:00
svastm
2198dccd6e
[NUCLEO_L432KC] Add to build and export scripts
2016-06-30 14:50:35 +02:00
Jarek Zgoda
2731bc7da3
Template moved to new tools directory
2016-06-30 12:36:19 +02:00
Jarek Zgoda
59623d62f9
One more occurence to be renamed
2016-06-30 12:36:19 +02:00
Jarek Zgoda
3006f70552
Support for Blue Pill
2016-06-30 12:36:18 +02:00
Sam Grove
472ac772f9
Merge pull request #2056 from theotherjimmy/pass-files-to-source
...
Enable passing individual files to --source options
2016-06-29 17:08:30 -05:00