mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2025-12-26 06:08:20 +00:00
@@ -1,7 +1,7 @@
|
||||
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
|
||||
actions:
|
||||
- set-value: |
|
||||
${BSP_OPTIMIZATION_FLAGS}
|
||||
${BSP_OPTIMIZATION_FLAGS} ${COVERAGE_COMPILER_FLAGS}
|
||||
- substitute: null
|
||||
- split: null
|
||||
- env-assign: null
|
||||
|
||||
@@ -67,6 +67,16 @@ links:
|
||||
uid: optszoff
|
||||
- role: build-dependency
|
||||
uid: optsztime
|
||||
- role: build-dependency
|
||||
uid: optcoverage
|
||||
- role: build-dependency
|
||||
uid: optcoveragecflags
|
||||
- role: build-dependency
|
||||
uid: optnocoveragecflags
|
||||
- role: build-dependency
|
||||
uid: optcoverageldflags
|
||||
- role: build-dependency
|
||||
uid: optnocoverageldflags
|
||||
- role: build-dependency
|
||||
uid: optversion
|
||||
target: cpukit/include/rtems/score/cpuopts.h
|
||||
|
||||
@@ -2,11 +2,13 @@ SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
|
||||
build-type: group
|
||||
cflags:
|
||||
- ${CPUKIT_OPTIMIZATION_FLAGS}
|
||||
- ${COVERAGE_COMPILER_FLAGS}
|
||||
copyrights:
|
||||
- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
|
||||
cppflags: []
|
||||
cxxflags:
|
||||
- ${CPUKIT_OPTIMIZATION_FLAGS}
|
||||
- ${COVERAGE_COMPILER_FLAGS}
|
||||
enabled-by: true
|
||||
includes: []
|
||||
install: []
|
||||
|
||||
16
spec/build/cpukit/optcoverage.yml
Normal file
16
spec/build/cpukit/optcoverage.yml
Normal file
@@ -0,0 +1,16 @@
|
||||
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
|
||||
actions:
|
||||
- get-boolean: null
|
||||
- env-enable: null
|
||||
- define-condition: null
|
||||
build-type: option
|
||||
copyrights:
|
||||
- Copyright (C) 2022 embedded brains GmbH (http://www.embedded-brains.de)
|
||||
default: false
|
||||
default-by-variant: []
|
||||
description: |
|
||||
Enable the code and branch coverage support.
|
||||
enabled-by: true
|
||||
links: []
|
||||
name: RTEMS_GCOV_COVERAGE
|
||||
type: build
|
||||
20
spec/build/cpukit/optcoveragecflags.yml
Normal file
20
spec/build/cpukit/optcoveragecflags.yml
Normal file
@@ -0,0 +1,20 @@
|
||||
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
|
||||
actions:
|
||||
- get-string: null
|
||||
- split: null
|
||||
- env-assign: null
|
||||
build-type: option
|
||||
copyrights:
|
||||
- Copyright (C) 2021 embedded brains GmbH (http://www.embedded-brains.de)
|
||||
default:
|
||||
- --coverage
|
||||
- -fprofile-info-section=.rtemsroset.gcov_info.content
|
||||
- -fprofile-update=atomic
|
||||
default-by-variant: []
|
||||
description: |
|
||||
Compiler flags recommended for components which should generate coverage
|
||||
information.
|
||||
enabled-by: RTEMS_GCOV_COVERAGE
|
||||
links: []
|
||||
name: COVERAGE_COMPILER_FLAGS
|
||||
type: build
|
||||
25
spec/build/cpukit/optcoverageldflags.yml
Normal file
25
spec/build/cpukit/optcoverageldflags.yml
Normal file
@@ -0,0 +1,25 @@
|
||||
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
|
||||
actions:
|
||||
- get-string: null
|
||||
- split: null
|
||||
- env-assign: null
|
||||
build-type: option
|
||||
copyrights:
|
||||
- Copyright (C) 2021 embedded brains GmbH (http://www.embedded-brains.de)
|
||||
default:
|
||||
- -Wl,--wrap=_CPU_Fatal_halt
|
||||
- -Wl,--wrap=bsp_reset
|
||||
- -Wl,--start-group
|
||||
- -lrtemsbsp
|
||||
- -lrtemscpu
|
||||
- -lrtemstest
|
||||
- -lgcov
|
||||
- -Wl,--end-group
|
||||
default-by-variant: []
|
||||
description: |
|
||||
Linker flags recommended for executables which contain modules with coverage
|
||||
information.
|
||||
enabled-by: RTEMS_GCOV_COVERAGE
|
||||
links: []
|
||||
name: COVERAGE_LINKER_FLAGS
|
||||
type: build
|
||||
18
spec/build/cpukit/optnocoveragecflags.yml
Normal file
18
spec/build/cpukit/optnocoveragecflags.yml
Normal file
@@ -0,0 +1,18 @@
|
||||
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
|
||||
actions:
|
||||
- get-string: null
|
||||
- split: null
|
||||
- env-assign: null
|
||||
build-type: option
|
||||
copyrights:
|
||||
- Copyright (C) 2021 embedded brains GmbH (http://www.embedded-brains.de)
|
||||
default: []
|
||||
default-by-variant: []
|
||||
description: |
|
||||
Compiler flags recommended for components which should generate coverage
|
||||
information.
|
||||
enabled-by:
|
||||
not: RTEMS_GCOV_COVERAGE
|
||||
links: []
|
||||
name: COVERAGE_COMPILER_FLAGS
|
||||
type: build
|
||||
18
spec/build/cpukit/optnocoverageldflags.yml
Normal file
18
spec/build/cpukit/optnocoverageldflags.yml
Normal file
@@ -0,0 +1,18 @@
|
||||
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
|
||||
actions:
|
||||
- get-string: null
|
||||
- split: null
|
||||
- env-assign: null
|
||||
build-type: option
|
||||
copyrights:
|
||||
- Copyright (C) 2021 embedded brains GmbH (http://www.embedded-brains.de)
|
||||
default: []
|
||||
default-by-variant: []
|
||||
description: |
|
||||
Linker flags recommended for executables which contain modules which generate
|
||||
coverage information.
|
||||
enabled-by:
|
||||
not: RTEMS_GCOV_COVERAGE
|
||||
links: []
|
||||
name: COVERAGE_LINKER_FLAGS
|
||||
type: build
|
||||
@@ -11,7 +11,8 @@ enabled-by: true
|
||||
includes:
|
||||
- ${BSP_INCLUDES}
|
||||
install: []
|
||||
ldflags: []
|
||||
ldflags:
|
||||
- ${COVERAGE_LINKER_FLAGS}
|
||||
links:
|
||||
- role: build-dependency
|
||||
uid: optada
|
||||
|
||||
@@ -150,7 +150,7 @@ void __wrap__CPU_Fatal_halt( uint32_t source, CPU_Uint32ptr code )
|
||||
halt_code = code;
|
||||
longjmp( before_terminate, 1 );
|
||||
} else {
|
||||
#if defined(RTEMS_COVERAGE)
|
||||
#if defined(RTEMS_GCOV_COVERAGE)
|
||||
rtems_test_gcov_dump_info();
|
||||
#endif
|
||||
__real__CPU_Fatal_halt( source, code );
|
||||
|
||||
@@ -65,7 +65,7 @@ extern "C" {
|
||||
|
||||
#define TEST_SCHEDULER_D_NAME rtems_build_name( 'D', ' ', ' ', ' ' )
|
||||
|
||||
#if defined( __OPTIMIZE__ ) && !defined( RTEMS_COVERAGE )
|
||||
#if defined( __OPTIMIZE__ ) && !defined( RTEMS_GCOV_COVERAGE )
|
||||
#define TEST_BASE_STACK_SIZE RTEMS_MINIMUM_STACK_SIZE
|
||||
#else
|
||||
#define TEST_BASE_STACK_SIZE ( 4 * RTEMS_MINIMUM_STACK_SIZE )
|
||||
|
||||
Reference in New Issue
Block a user