]> begriffs open source - cmsis/blob - CMSIS/Core/Test/ipsr.c
Add LLVM LIT/FileCheck tests for Core files
[cmsis] / CMSIS / Core / Test / ipsr.c
1
2 // REQUIRES: thumbv6m
3 // RUN: %cc% %ccflags% %ccout% %s.o %s; llvm-objdump --mcpu=%mcpu% -d %s.o | FileCheck --allow-unused-prefixes --check-prefixes %prefixes% %s
4
5 #include "cmsis_compiler.h"
6
7 void get_ipsr() {
8     // CHECK-LABEL: <get_ipsr>:
9     // CHECK: mrs {{r[0-9]+}}, ipsr
10     volatile uint32_t result = __get_IPSR();
11     // CHECK: {{(bx lr)|(pop {.*pc})}}
12 }