aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Quist <partouf@gmail.com>2023-01-31 14:54:43 +0100
committerGitHub <noreply@github.com>2023-01-31 07:54:43 -0600
commita16cb5a0cf7c5997efdd85ddfa2dfcb8be86d676 (patch)
tree0e79ecf65b0ea46d8a3198b162c8773edf2a0b42
parent621f43a56f434dbecdc655f9ff7a18d45a0d913c (diff)
downloadcompiler-explorer-gh-6077.tar.gz
compiler-explorer-gh-6077.zip
ewarm things (#4056)gh-6077
Co-authored-by: Matt Godbolt <matt@godbolt.org>
-rw-r--r--test/filter-tests.js2
-rw-r--r--test/filters-cases/ewarm-1.asm414
-rw-r--r--test/filters-cases/ewarm-1.asm.binary.directives.labels.comments.approved.txt969
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.approved.txt1757
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.comments.approved.txt969
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.labels.approved.txt1757
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.labels.comments.approved.txt969
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.labels.comments.json1443
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.labels.comments.library.approved.txt969
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.labels.comments.library.dontMaskFilenames.approved.txt969
-rw-r--r--test/filters-cases/ewarm-1.asm.directives.library.approved.txt1757
-rw-r--r--test/filters-cases/ewarm-1.asm.none.approved.txt2077
-rw-r--r--test/filters-cases/ewarm-1.cpp129
13 files changed, 14181 insertions, 0 deletions
diff --git a/test/filter-tests.js b/test/filter-tests.js
index 533c6fdf7..5fc93b362 100644
--- a/test/filter-tests.js
+++ b/test/filter-tests.js
@@ -28,6 +28,7 @@ import approvals from 'approvals';
import {AsmParser} from '../lib/parsers/asm-parser';
import {CC65AsmParser} from '../lib/parsers/asm-parser-cc65';
+import {AsmEWAVRParser} from '../lib/parsers/asm-parser-ewavr';
import {SassAsmParser} from '../lib/parsers/asm-parser-sass';
import {VcAsmParser} from '../lib/parsers/asm-parser-vc';
@@ -41,6 +42,7 @@ function processAsm(filename, filters) {
if (file.includes('Microsoft')) parser = new VcAsmParser();
else if (filename.includes('sass-')) parser = new SassAsmParser();
else if (filename.includes('cc65-')) parser = new CC65AsmParser();
+ else if (filename.includes('ewarm-')) parser = new AsmEWAVRParser();
else {
parser = new AsmParser();
parser.binaryHideFuncRe =
diff --git a/test/filters-cases/ewarm-1.asm b/test/filters-cases/ewarm-1.asm
new file mode 100644
index 000000000..d391fe55c
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm
@@ -0,0 +1,414 @@
+///////////////////////////////////////////////////////////////////////////////
+//
+// IAR ANSI C/C++ Compiler V8.32.3.193/W32 for ARM 09/Oct/2020 12:40:07
+// Copyright 1999-2019 IAR Systems AB.
+//
+// Cpu mode =
+// Endian = little
+// Source file =
+// C:\Users\NA_BUI~1\AppData\Local\Temp\compiler-explorer-compiler202099-14988-evjfs2.ood3c\example.cpp
+// Command line =
+// -lB
+// C:\Users\NA_BUI~1\AppData\Local\Temp\compiler-explorer-compiler202099-14988-evjfs2.ood3c\output.s
+// -o
+// C:\Users\NA_BUI~1\AppData\Local\Temp\compiler-explorer-compiler202099-14988-evjfs2.ood3c\output.s.obj
+// --enable_restrict -IC:\arm\inc -IC:\arm\inc\c -IC:\arm\inc\cpp
+// --dlib_config C:\arm\inc\c\DLib_Config_Full.h --c++ -e
+// --no_exceptions --no_rtti --no_static_destruction --cpu Cortex-M4
+// --fpu VFPv4_sp --endian little --cpu_mode thumb
+// C:\Users\NA_BUI~1\AppData\Local\Temp\compiler-explorer-compiler202099-14988-evjfs2.ood3c\example.cpp
+// Locale = C
+// List file =
+// C:\Users\NA_BUI~1\AppData\Local\Temp\compiler-explorer-compiler202099-14988-evjfs2.ood3c\output.s
+//
+///////////////////////////////////////////////////////////////////////////////
+
+ #define SHT_PROGBITS 0x1
+ #define SHT_INIT_ARRAY 0xe
+
+ EXTERN printf
+
+ PUBLIC _ZN2NA10FixedStackIiLj16EE11IteratorEndEv
+ PUBLIC _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv
+ PUBLIC _ZN2NA10FixedStackIiLj16EE4PushEi
+ PUBLIC _ZN2NA10FixedStackIiLj16EEC1Ev
+ PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv
+ PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv
+ PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi
+ PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv
+ PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv
+ PUBLIC _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_
+ PUBLIC _ZNSt5arrayIiLj16EE4dataEv
+ PUBLIC _ZNSt5arrayIiLj16EEixEj
+ PUBLIC desa
+ PUBLIC main
+
+// C:\Users\NA_BUI~1\AppData\Local\Temp\compiler-explorer-compiler202099-14988-evjfs2.ood3c\example.cpp
+// 1 #include <array>
+// 2
+// 3 namespace NA {
+// 4
+// 5 template<class Derived, typename DataType>
+// 6 class Iterator {
+// 7 public:
+// 8 Iterator() = default;
+// 9
+// 10 class iterator {
+// 11 public:
+// 12 iterator(DataType* ptr = nullptr) : ptr(ptr) {}
+// 13 inline iterator operator++() {
+// 14 ++ptr;
+// 15 return *this;
+// 16 }
+// 17 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }
+// 18 inline DataType& operator*() { return *ptr; }
+// 19
+// 20 private:
+// 21 DataType* ptr;
+// 22 };
+// 23
+// 24 class const_iterator {
+// 25 public:
+// 26 const_iterator(const DataType* ptr = nullptr) : ptr(ptr) {}
+// 27 inline const_iterator operator++() {
+// 28 ++ptr;
+// 29 return *this;
+// 30 }
+// 31 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }
+// 32 inline const DataType& operator*() const { return *ptr; }
+// 33
+// 34 private:
+// 35 const DataType* ptr;
+// 36 };
+// 37
+// 38 inline iterator begin() { return iterator((DataType*)((Derived*)this)->IteratorBegin()); }
+// 39 inline iterator end() { return iterator((DataType*)((Derived*)this)->IteratorEnd()); }
+// 40 inline const_iterator begin() const { return const_iterator((const DataType*)((Derived*)this)->IteratorBegin()); }
+// 41 inline const_iterator end() const { return const_iterator((const DataType*)((Derived*)this)->IteratorEnd()); }
+// 42 };
+// 43
+// 44 } // namespace NA
+// 45
+// 46
+// 47 namespace NA {
+// 48 template<typename T, unsigned int MAX_SIZE>
+// 49 class FixedStack : public Iterator<FixedStack<T, MAX_SIZE>, T> {
+// 50 friend class Iterator<FixedStack<T, MAX_SIZE>, T>;
+// 51 inline constexpr auto IteratorBegin() { return m_Stack.data(); }
+// 52 inline constexpr auto IteratorEnd() { return m_Stack.data() + m_Pos + 1; }
+// 53
+// 54 public:
+// 55 FixedStack() : m_Pos(-1) {}
+// 56
+// 57 inline bool Push(T elem) {
+// 58 if ((m_Pos + 1) < MAX_SIZE) {
+// 59 m_Pos++;
+// 60 m_Stack[m_Pos] = elem;
+// 61 return true;
+// 62 }
+// 63
+// 64 return false;
+// 65 }
+// 66
+// 67 inline bool Pop(T replaceLast) {
+// 68 if (m_Pos != -1) {
+// 69 m_Stack[m_Pos--] = replaceLast;
+// 70 return true;
+// 71 }
+// 72
+// 73 return false;
+// 74 }
+// 75
+// 76 inline bool Pop() {
+// 77 if (m_Pos != -1) {
+// 78 m_Pos--;
+// 79 return true;
+// 80 }
+// 81
+// 82 return false;
+// 83 }
+// 84
+// 85 inline void Clear(T fill) {
+// 86 m_Pos = -1;
+// 87 m_Stack.fill(fill);
+// 88 }
+// 89
+// 90 inline void Clear() { m_Pos = -1; }
+// 91
+// 92 inline int FreeSpace() { return (MAX_SIZE - (m_Pos + 1)); }
+// 93
+// 94 inline T* DataPtr() const { return m_Stack.data(); }
+// 95
+// 96 inline int Size() const { return m_Pos + 1; }
+// 97
+// 98 inline bool Full() { return Size() == MAX_SIZE; }
+// 99
+// 100 inline T& Top(int back = 0) {
+// 101 return m_Stack[m_Pos + back];
+// 102 }
+// 103
+// 104 inline bool Empty() const { return m_Pos == -1; }
+// 105
+// 106 inline T& operator[](int index) { return m_Stack[index]; }
+// 107 inline const T& operator[](int index) const { return m_Stack[index]; }
+// 108
+// 109 private:
+// 110 int m_Pos;
+// 111 std::array<T, MAX_SIZE> m_Stack;
+// 112 };
+// 113
+// 114 } // namespace NA
+// 115
+
+ SECTION `.text`:CODE:NOROOT(1)
+ THUMB
+// static __intrinsic __interwork __softfp void __sti__routine()
+__sti__routine:
+ PUSH {R7,LR}
+// 116 NA::FixedStack<int, 16> desa;
+ LDR.N R0,??DataTable1_1
+ BL _ZN2NA10FixedStackIiLj16EEC1Ev
+ POP {R0,PC} ;; return
+
+ SECTION `.bss`:DATA:REORDER:NOROOT(2)
+ DATA
+desa:
+ DS8 68
+
+ SECTION `.text`:CODE:NOROOT(1)
+ THUMB
+main:
+ PUSH {R2-R4,LR}
+ LDR.N R4,??DataTable1_1
+ MOVS R1,#+1
+ MOVS R0,R4
+ BL _ZN2NA10FixedStackIiLj16EE4PushEi
+ MOVS R1,#+2
+ MOVS R0,R4
+ BL _ZN2NA10FixedStackIiLj16EE4PushEi
+ MOVS R1,#+3
+ MOVS R0,R4
+ BL _ZN2NA10FixedStackIiLj16EE4PushEi
+ MOVS R1,#+4
+ MOVS R0,R4
+ BL _ZN2NA10FixedStackIiLj16EE4PushEi
+ MOVS R0,R4
+ BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv
+ STR R0,[SP, #+0]
+ MOVS R0,R4
+ BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv
+ STR R0,[SP, #+4]
+ B.N ??main_0
+??main_1:
+ MOV R0,SP
+ BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv
+ LDR R1,[R0, #+0]
+ ADR.N R0,??DataTable1 ;; "%d\n"
+ BL printf
+ MOV R0,SP
+ BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv
+??main_0:
+ ADD R1,SP,#+4
+ MOV R0,SP
+ BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_
+ CMP R0,#+0
+ BNE.N ??main_1
+ POP {R0,R1,R4,PC} ;; return
+
+ SECTION `.text`:CODE:NOROOT(2)
+ SECTION_TYPE SHT_PROGBITS, 0
+ DATA
+??DataTable1:
+ DATA8
+ DC8 "%d\n"
+
+ SECTION `.text`:CODE:NOROOT(2)
+ SECTION_TYPE SHT_PROGBITS, 0
+ DATA
+??DataTable1_1:
+ DATA32
+ DC32 desa
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZNSt5arrayIiLj16EEixEj
+ THUMB
+// __interwork __softfp int & std::array<int, 16U>::operator[](size_t)
+_ZNSt5arrayIiLj16EEixEj:
+ ADD R0,R0,R1, LSL #+2
+ BX LR ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZNSt5arrayIiLj16EE4dataEv
+ THUMB
+// __interwork __softfp int *std::array<int, 16U>::data()
+_ZNSt5arrayIiLj16EE4dataEv:
+ BX LR ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi
+ THUMB
+// __code __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::iterator(int *)
+_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:
+ STR R1,[R0, #+0]
+ BX LR ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv
+ THUMB
+// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator++()
+_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:
+ LDR R1,[R0, #+0]
+ ADDS R1,R1,#+4
+ STR R1,[R0, #+0]
+ LDR R0,[R0, #+0]
+ BX LR ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_
+ THUMB
+// __interwork __softfp bool NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator!=(NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator const &) const
+_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:
+ LDR R0,[R0, #+0]
+ LDR R1,[R1, #+0]
+ CMP R0,R1
+ BEQ.N `??operator!=_0`
+ MOVS R0,#+1
+ B.N `??operator!=_1`
+`??operator!=_0`:
+ MOVS R0,#+0
+`??operator!=_1`:
+ UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24
+ BX LR ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv
+ THUMB
+// __interwork __softfp int &NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator*()
+_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:
+ LDR R0,[R0, #+0]
+ BX LR ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv
+ THUMB
+// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::begin()
+_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:
+ PUSH {R7,LR}
+ BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv
+ MOVS R1,R0
+ MOV R0,SP
+ BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi
+ LDR R0,[R0, #+0]
+ POP {R1,PC} ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv
+ THUMB
+// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::end()
+_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:
+ PUSH {R7,LR}
+ BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv
+ MOVS R1,R0
+ MOV R0,SP
+ BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi
+ LDR R0,[R0, #+0]
+ POP {R1,PC} ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv
+ THUMB
+// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorBegin()
+_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:
+ PUSH {R7,LR}
+ ADDS R0,R0,#+4
+ BL _ZNSt5arrayIiLj16EE4dataEv
+ POP {R1,PC} ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA10FixedStackIiLj16EE11IteratorEndEv
+ THUMB
+// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorEnd()
+_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:
+ PUSH {R4,LR}
+ MOVS R4,R0
+ ADDS R0,R4,#+4
+ BL _ZNSt5arrayIiLj16EE4dataEv
+ LDR R1,[R4, #+0]
+ ADD R0,R0,R1, LSL #+2
+ ADDS R0,R0,#+4
+ POP {R4,PC} ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA10FixedStackIiLj16EEC1Ev
+ THUMB
+// __code __interwork __softfp NA::FixedStack<int, 16U>::FixedStack()
+_ZN2NA10FixedStackIiLj16EEC1Ev:
+ MOVS R1,#-1
+ STR R1,[R0, #+0]
+ BX LR ;; return
+
+ SECTION `.text`:CODE:REORDER:NOROOT(1)
+ SECTION_GROUP _ZN2NA10FixedStackIiLj16EE4PushEi
+ THUMB
+// __interwork __softfp bool NA::FixedStack<int, 16U>::Push(int)
+_ZN2NA10FixedStackIiLj16EE4PushEi:
+ PUSH {R4,LR}
+ MOVS R4,R1
+ LDR R1,[R0, #+0]
+ ADDS R1,R1,#+1
+ CMP R1,#+16
+ BCS.N ??Push_0
+ LDR R1,[R0, #+0]
+ ADDS R1,R1,#+1
+ STR R1,[R0, #+0]
+ LDR R1,[R0, #+0]
+ ADDS R0,R0,#+4
+ BL _ZNSt5arrayIiLj16EEixEj
+ STR R4,[R0, #+0]
+ MOVS R0,#+1
+ B.N ??Push_1
+??Push_0:
+ MOVS R0,#+0
+??Push_1:
+ POP {R4,PC} ;; return
+
+ SECTION `.init_array`:CODE:ROOT(2)
+ SECTION_TYPE SHT_INIT_ARRAY, 0
+ DATA
+ DC32 RELOC_ARM_TARGET1 __sti__routine
+
+ SECTION `.iar_vfe_header`:DATA:NOALLOC:NOROOT(2)
+ SECTION_TYPE SHT_PROGBITS, 0
+ DATA
+ DC32 0
+
+ SECTION `.rodata`:CONST:REORDER:NOROOT(2)
+ DATA
+ DC8 "%d\012"
+
+ END
+// 117
+// 118 void main() {
+// 119
+// 120
+// 121 desa.Push(1);
+// 122 desa.Push(2);
+// 123 desa.Push(3);
+// 124 desa.Push(4);
+// 125
+// 126 for(auto d : desa) {
+// 127 printf("%d\n", d);
+// 128 }
+// 129 }
+//
+// 68 bytes in section .bss
+// 4 bytes in section .init_array
+// 4 bytes in section .rodata
+// 260 bytes in section .text
+//
+// 110 bytes of CODE memory (+ 154 bytes shared)
+// 4 bytes of CONST memory
+// 68 bytes of DATA memory
+//
+//Errors: none
+//Warnings: none
diff --git a/test/filters-cases/ewarm-1.asm.binary.directives.labels.comments.approved.txt b/test/filters-cases/ewarm-1.asm.binary.directives.labels.comments.approved.txt
new file mode 100644
index 000000000..063389250
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.binary.directives.labels.comments.approved.txt
@@ -0,0 +1,969 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.approved.txt b/test/filters-cases/ewarm-1.asm.directives.approved.txt
new file mode 100644
index 000000000..8e27a595e
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.approved.txt
@@ -0,0 +1,1757 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// IAR ANSI C/C++ Compiler V8.32.3.193/W32 for ARM 09/Oct/2020 12:40:07"
+ },
+ {
+ "source": null,
+ "text": "// Copyright 1999-2019 IAR Systems AB."
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// Cpu mode ="
+ },
+ {
+ "source": null,
+ "text": "// Endian = little"
+ },
+ {
+ "source": null,
+ "text": "// Source file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Command line ="
+ },
+ {
+ "source": null,
+ "text": "// -lB"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "// -o"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s.obj"
+ },
+ {
+ "source": null,
+ "text": "// --enable_restrict -IC:\\arm\\inc -IC:\\arm\\inc\\c -IC:\\arm\\inc\\cpp"
+ },
+ {
+ "source": null,
+ "text": "// --dlib_config C:\\arm\\inc\\c\\DLib_Config_Full.h --c++ -e"
+ },
+ {
+ "source": null,
+ "text": "// --no_exceptions --no_rtti --no_static_destruction --cpu Cortex-M4"
+ },
+ {
+ "source": null,
+ "text": "// --fpu VFPv4_sp --endian little --cpu_mode thumb"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Locale = C"
+ },
+ {
+ "source": null,
+ "text": "// List file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " #define SHT_PROGBITS 0x1"
+ },
+ {
+ "source": null,
+ "text": " #define SHT_INIT_ARRAY 0xe"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// 1 #include <array>"
+ },
+ {
+ "source": null,
+ "text": "// 2"
+ },
+ {
+ "source": null,
+ "text": "// 3 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 4"
+ },
+ {
+ "source": null,
+ "text": "// 5 template<class Derived, typename DataType>"
+ },
+ {
+ "source": null,
+ "text": "// 6 class Iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 7 public:"
+ },
+ {
+ "source": null,
+ "text": "// 8 Iterator() = default;"
+ },
+ {
+ "source": null,
+ "text": "// 9"
+ },
+ {
+ "source": null,
+ "text": "// 10 class iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 11 public:"
+ },
+ {
+ "source": null,
+ "text": "// 12 iterator(DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 13 inline iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 14 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 15 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 16 }"
+ },
+ {
+ "source": null,
+ "text": "// 17 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 18 inline DataType& operator*() { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 19"
+ },
+ {
+ "source": null,
+ "text": "// 20 private:"
+ },
+ {
+ "source": null,
+ "text": "// 21 DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 22 };"
+ },
+ {
+ "source": null,
+ "text": "// 23"
+ },
+ {
+ "source": null,
+ "text": "// 24 class const_iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 25 public:"
+ },
+ {
+ "source": null,
+ "text": "// 26 const_iterator(const DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 27 inline const_iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 28 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 29 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 30 }"
+ },
+ {
+ "source": null,
+ "text": "// 31 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 32 inline const DataType& operator*() const { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 33"
+ },
+ {
+ "source": null,
+ "text": "// 34 private:"
+ },
+ {
+ "source": null,
+ "text": "// 35 const DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 36 };"
+ },
+ {
+ "source": null,
+ "text": "// 37"
+ },
+ {
+ "source": null,
+ "text": "// 38 inline iterator begin() { return iterator((DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 39 inline iterator end() { return iterator((DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 40 inline const_iterator begin() const { return const_iterator((const DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 41 inline const_iterator end() const { return const_iterator((const DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 42 };"
+ },
+ {
+ "source": null,
+ "text": "// 43"
+ },
+ {
+ "source": null,
+ "text": "// 44 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 45"
+ },
+ {
+ "source": null,
+ "text": "// 46"
+ },
+ {
+ "source": null,
+ "text": "// 47 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 48 template<typename T, unsigned int MAX_SIZE>"
+ },
+ {
+ "source": null,
+ "text": "// 49 class FixedStack : public Iterator<FixedStack<T, MAX_SIZE>, T> {"
+ },
+ {
+ "source": null,
+ "text": "// 50 friend class Iterator<FixedStack<T, MAX_SIZE>, T>;"
+ },
+ {
+ "source": null,
+ "text": "// 51 inline constexpr auto IteratorBegin() { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 52 inline constexpr auto IteratorEnd() { return m_Stack.data() + m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 53"
+ },
+ {
+ "source": null,
+ "text": "// 54 public:"
+ },
+ {
+ "source": null,
+ "text": "// 55 FixedStack() : m_Pos(-1) {}"
+ },
+ {
+ "source": null,
+ "text": "// 56"
+ },
+ {
+ "source": null,
+ "text": "// 57 inline bool Push(T elem) {"
+ },
+ {
+ "source": null,
+ "text": "// 58 if ((m_Pos + 1) < MAX_SIZE) {"
+ },
+ {
+ "source": null,
+ "text": "// 59 m_Pos++;"
+ },
+ {
+ "source": null,
+ "text": "// 60 m_Stack[m_Pos] = elem;"
+ },
+ {
+ "source": null,
+ "text": "// 61 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 62 }"
+ },
+ {
+ "source": null,
+ "text": "// 63"
+ },
+ {
+ "source": null,
+ "text": "// 64 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 65 }"
+ },
+ {
+ "source": null,
+ "text": "// 66"
+ },
+ {
+ "source": null,
+ "text": "// 67 inline bool Pop(T replaceLast) {"
+ },
+ {
+ "source": null,
+ "text": "// 68 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 69 m_Stack[m_Pos--] = replaceLast;"
+ },
+ {
+ "source": null,
+ "text": "// 70 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 71 }"
+ },
+ {
+ "source": null,
+ "text": "// 72"
+ },
+ {
+ "source": null,
+ "text": "// 73 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 74 }"
+ },
+ {
+ "source": null,
+ "text": "// 75"
+ },
+ {
+ "source": null,
+ "text": "// 76 inline bool Pop() {"
+ },
+ {
+ "source": null,
+ "text": "// 77 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 78 m_Pos--;"
+ },
+ {
+ "source": null,
+ "text": "// 79 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 80 }"
+ },
+ {
+ "source": null,
+ "text": "// 81"
+ },
+ {
+ "source": null,
+ "text": "// 82 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 83 }"
+ },
+ {
+ "source": null,
+ "text": "// 84"
+ },
+ {
+ "source": null,
+ "text": "// 85 inline void Clear(T fill) {"
+ },
+ {
+ "source": null,
+ "text": "// 86 m_Pos = -1;"
+ },
+ {
+ "source": null,
+ "text": "// 87 m_Stack.fill(fill);"
+ },
+ {
+ "source": null,
+ "text": "// 88 }"
+ },
+ {
+ "source": null,
+ "text": "// 89"
+ },
+ {
+ "source": null,
+ "text": "// 90 inline void Clear() { m_Pos = -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 91"
+ },
+ {
+ "source": null,
+ "text": "// 92 inline int FreeSpace() { return (MAX_SIZE - (m_Pos + 1)); }"
+ },
+ {
+ "source": null,
+ "text": "// 93"
+ },
+ {
+ "source": null,
+ "text": "// 94 inline T* DataPtr() const { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 95"
+ },
+ {
+ "source": null,
+ "text": "// 96 inline int Size() const { return m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 97"
+ },
+ {
+ "source": null,
+ "text": "// 98 inline bool Full() { return Size() == MAX_SIZE; }"
+ },
+ {
+ "source": null,
+ "text": "// 99"
+ },
+ {
+ "source": null,
+ "text": "// 100 inline T& Top(int back = 0) {"
+ },
+ {
+ "source": null,
+ "text": "// 101 return m_Stack[m_Pos + back];"
+ },
+ {
+ "source": null,
+ "text": "// 102 }"
+ },
+ {
+ "source": null,
+ "text": "// 103"
+ },
+ {
+ "source": null,
+ "text": "// 104 inline bool Empty() const { return m_Pos == -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 105"
+ },
+ {
+ "source": null,
+ "text": "// 106 inline T& operator[](int index) { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 107 inline const T& operator[](int index) const { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 108"
+ },
+ {
+ "source": null,
+ "text": "// 109 private:"
+ },
+ {
+ "source": null,
+ "text": "// 110 int m_Pos;"
+ },
+ {
+ "source": null,
+ "text": "// 111 std::array<T, MAX_SIZE> m_Stack;"
+ },
+ {
+ "source": null,
+ "text": "// 112 };"
+ },
+ {
+ "source": null,
+ "text": "// 113"
+ },
+ {
+ "source": null,
+ "text": "// 114 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 115"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// static __intrinsic __interwork __softfp void __sti__routine()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": null,
+ "text": "// 116 NA::FixedStack<int, 16> desa;"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int & std::array<int, 16U>::operator[](size_t)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *std::array<int, 16U>::data()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::iterator(int *)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator++()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator!=(NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator const &) const"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int &NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator*()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::begin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::end()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorBegin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorEnd()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::FixedStack<int, 16U>::FixedStack()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::FixedStack<int, 16U>::Push(int)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// 117"
+ },
+ {
+ "source": null,
+ "text": "// 118 void main() {"
+ },
+ {
+ "source": null,
+ "text": "// 119"
+ },
+ {
+ "source": null,
+ "text": "// 120"
+ },
+ {
+ "source": null,
+ "text": "// 121 desa.Push(1);"
+ },
+ {
+ "source": null,
+ "text": "// 122 desa.Push(2);"
+ },
+ {
+ "source": null,
+ "text": "// 123 desa.Push(3);"
+ },
+ {
+ "source": null,
+ "text": "// 124 desa.Push(4);"
+ },
+ {
+ "source": null,
+ "text": "// 125"
+ },
+ {
+ "source": null,
+ "text": "// 126 for(auto d : desa) {"
+ },
+ {
+ "source": null,
+ "text": "// 127 printf(\"%d\\n\", d);"
+ },
+ {
+ "source": null,
+ "text": "// 128 }"
+ },
+ {
+ "source": null,
+ "text": "// 129 }"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes in section .bss"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .init_array"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .rodata"
+ },
+ {
+ "source": null,
+ "text": "// 260 bytes in section .text"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 110 bytes of CODE memory (+ 154 bytes shared)"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes of CONST memory"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes of DATA memory"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "//Errors: none"
+ },
+ {
+ "source": null,
+ "text": "//Warnings: none"
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.comments.approved.txt b/test/filters-cases/ewarm-1.asm.directives.comments.approved.txt
new file mode 100644
index 000000000..063389250
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.comments.approved.txt
@@ -0,0 +1,969 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.labels.approved.txt b/test/filters-cases/ewarm-1.asm.directives.labels.approved.txt
new file mode 100644
index 000000000..8e27a595e
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.labels.approved.txt
@@ -0,0 +1,1757 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// IAR ANSI C/C++ Compiler V8.32.3.193/W32 for ARM 09/Oct/2020 12:40:07"
+ },
+ {
+ "source": null,
+ "text": "// Copyright 1999-2019 IAR Systems AB."
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// Cpu mode ="
+ },
+ {
+ "source": null,
+ "text": "// Endian = little"
+ },
+ {
+ "source": null,
+ "text": "// Source file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Command line ="
+ },
+ {
+ "source": null,
+ "text": "// -lB"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "// -o"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s.obj"
+ },
+ {
+ "source": null,
+ "text": "// --enable_restrict -IC:\\arm\\inc -IC:\\arm\\inc\\c -IC:\\arm\\inc\\cpp"
+ },
+ {
+ "source": null,
+ "text": "// --dlib_config C:\\arm\\inc\\c\\DLib_Config_Full.h --c++ -e"
+ },
+ {
+ "source": null,
+ "text": "// --no_exceptions --no_rtti --no_static_destruction --cpu Cortex-M4"
+ },
+ {
+ "source": null,
+ "text": "// --fpu VFPv4_sp --endian little --cpu_mode thumb"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Locale = C"
+ },
+ {
+ "source": null,
+ "text": "// List file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " #define SHT_PROGBITS 0x1"
+ },
+ {
+ "source": null,
+ "text": " #define SHT_INIT_ARRAY 0xe"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// 1 #include <array>"
+ },
+ {
+ "source": null,
+ "text": "// 2"
+ },
+ {
+ "source": null,
+ "text": "// 3 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 4"
+ },
+ {
+ "source": null,
+ "text": "// 5 template<class Derived, typename DataType>"
+ },
+ {
+ "source": null,
+ "text": "// 6 class Iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 7 public:"
+ },
+ {
+ "source": null,
+ "text": "// 8 Iterator() = default;"
+ },
+ {
+ "source": null,
+ "text": "// 9"
+ },
+ {
+ "source": null,
+ "text": "// 10 class iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 11 public:"
+ },
+ {
+ "source": null,
+ "text": "// 12 iterator(DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 13 inline iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 14 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 15 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 16 }"
+ },
+ {
+ "source": null,
+ "text": "// 17 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 18 inline DataType& operator*() { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 19"
+ },
+ {
+ "source": null,
+ "text": "// 20 private:"
+ },
+ {
+ "source": null,
+ "text": "// 21 DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 22 };"
+ },
+ {
+ "source": null,
+ "text": "// 23"
+ },
+ {
+ "source": null,
+ "text": "// 24 class const_iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 25 public:"
+ },
+ {
+ "source": null,
+ "text": "// 26 const_iterator(const DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 27 inline const_iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 28 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 29 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 30 }"
+ },
+ {
+ "source": null,
+ "text": "// 31 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 32 inline const DataType& operator*() const { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 33"
+ },
+ {
+ "source": null,
+ "text": "// 34 private:"
+ },
+ {
+ "source": null,
+ "text": "// 35 const DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 36 };"
+ },
+ {
+ "source": null,
+ "text": "// 37"
+ },
+ {
+ "source": null,
+ "text": "// 38 inline iterator begin() { return iterator((DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 39 inline iterator end() { return iterator((DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 40 inline const_iterator begin() const { return const_iterator((const DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 41 inline const_iterator end() const { return const_iterator((const DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 42 };"
+ },
+ {
+ "source": null,
+ "text": "// 43"
+ },
+ {
+ "source": null,
+ "text": "// 44 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 45"
+ },
+ {
+ "source": null,
+ "text": "// 46"
+ },
+ {
+ "source": null,
+ "text": "// 47 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 48 template<typename T, unsigned int MAX_SIZE>"
+ },
+ {
+ "source": null,
+ "text": "// 49 class FixedStack : public Iterator<FixedStack<T, MAX_SIZE>, T> {"
+ },
+ {
+ "source": null,
+ "text": "// 50 friend class Iterator<FixedStack<T, MAX_SIZE>, T>;"
+ },
+ {
+ "source": null,
+ "text": "// 51 inline constexpr auto IteratorBegin() { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 52 inline constexpr auto IteratorEnd() { return m_Stack.data() + m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 53"
+ },
+ {
+ "source": null,
+ "text": "// 54 public:"
+ },
+ {
+ "source": null,
+ "text": "// 55 FixedStack() : m_Pos(-1) {}"
+ },
+ {
+ "source": null,
+ "text": "// 56"
+ },
+ {
+ "source": null,
+ "text": "// 57 inline bool Push(T elem) {"
+ },
+ {
+ "source": null,
+ "text": "// 58 if ((m_Pos + 1) < MAX_SIZE) {"
+ },
+ {
+ "source": null,
+ "text": "// 59 m_Pos++;"
+ },
+ {
+ "source": null,
+ "text": "// 60 m_Stack[m_Pos] = elem;"
+ },
+ {
+ "source": null,
+ "text": "// 61 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 62 }"
+ },
+ {
+ "source": null,
+ "text": "// 63"
+ },
+ {
+ "source": null,
+ "text": "// 64 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 65 }"
+ },
+ {
+ "source": null,
+ "text": "// 66"
+ },
+ {
+ "source": null,
+ "text": "// 67 inline bool Pop(T replaceLast) {"
+ },
+ {
+ "source": null,
+ "text": "// 68 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 69 m_Stack[m_Pos--] = replaceLast;"
+ },
+ {
+ "source": null,
+ "text": "// 70 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 71 }"
+ },
+ {
+ "source": null,
+ "text": "// 72"
+ },
+ {
+ "source": null,
+ "text": "// 73 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 74 }"
+ },
+ {
+ "source": null,
+ "text": "// 75"
+ },
+ {
+ "source": null,
+ "text": "// 76 inline bool Pop() {"
+ },
+ {
+ "source": null,
+ "text": "// 77 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 78 m_Pos--;"
+ },
+ {
+ "source": null,
+ "text": "// 79 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 80 }"
+ },
+ {
+ "source": null,
+ "text": "// 81"
+ },
+ {
+ "source": null,
+ "text": "// 82 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 83 }"
+ },
+ {
+ "source": null,
+ "text": "// 84"
+ },
+ {
+ "source": null,
+ "text": "// 85 inline void Clear(T fill) {"
+ },
+ {
+ "source": null,
+ "text": "// 86 m_Pos = -1;"
+ },
+ {
+ "source": null,
+ "text": "// 87 m_Stack.fill(fill);"
+ },
+ {
+ "source": null,
+ "text": "// 88 }"
+ },
+ {
+ "source": null,
+ "text": "// 89"
+ },
+ {
+ "source": null,
+ "text": "// 90 inline void Clear() { m_Pos = -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 91"
+ },
+ {
+ "source": null,
+ "text": "// 92 inline int FreeSpace() { return (MAX_SIZE - (m_Pos + 1)); }"
+ },
+ {
+ "source": null,
+ "text": "// 93"
+ },
+ {
+ "source": null,
+ "text": "// 94 inline T* DataPtr() const { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 95"
+ },
+ {
+ "source": null,
+ "text": "// 96 inline int Size() const { return m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 97"
+ },
+ {
+ "source": null,
+ "text": "// 98 inline bool Full() { return Size() == MAX_SIZE; }"
+ },
+ {
+ "source": null,
+ "text": "// 99"
+ },
+ {
+ "source": null,
+ "text": "// 100 inline T& Top(int back = 0) {"
+ },
+ {
+ "source": null,
+ "text": "// 101 return m_Stack[m_Pos + back];"
+ },
+ {
+ "source": null,
+ "text": "// 102 }"
+ },
+ {
+ "source": null,
+ "text": "// 103"
+ },
+ {
+ "source": null,
+ "text": "// 104 inline bool Empty() const { return m_Pos == -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 105"
+ },
+ {
+ "source": null,
+ "text": "// 106 inline T& operator[](int index) { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 107 inline const T& operator[](int index) const { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 108"
+ },
+ {
+ "source": null,
+ "text": "// 109 private:"
+ },
+ {
+ "source": null,
+ "text": "// 110 int m_Pos;"
+ },
+ {
+ "source": null,
+ "text": "// 111 std::array<T, MAX_SIZE> m_Stack;"
+ },
+ {
+ "source": null,
+ "text": "// 112 };"
+ },
+ {
+ "source": null,
+ "text": "// 113"
+ },
+ {
+ "source": null,
+ "text": "// 114 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 115"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// static __intrinsic __interwork __softfp void __sti__routine()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": null,
+ "text": "// 116 NA::FixedStack<int, 16> desa;"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int & std::array<int, 16U>::operator[](size_t)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *std::array<int, 16U>::data()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::iterator(int *)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator++()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator!=(NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator const &) const"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int &NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator*()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::begin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::end()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorBegin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorEnd()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::FixedStack<int, 16U>::FixedStack()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::FixedStack<int, 16U>::Push(int)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// 117"
+ },
+ {
+ "source": null,
+ "text": "// 118 void main() {"
+ },
+ {
+ "source": null,
+ "text": "// 119"
+ },
+ {
+ "source": null,
+ "text": "// 120"
+ },
+ {
+ "source": null,
+ "text": "// 121 desa.Push(1);"
+ },
+ {
+ "source": null,
+ "text": "// 122 desa.Push(2);"
+ },
+ {
+ "source": null,
+ "text": "// 123 desa.Push(3);"
+ },
+ {
+ "source": null,
+ "text": "// 124 desa.Push(4);"
+ },
+ {
+ "source": null,
+ "text": "// 125"
+ },
+ {
+ "source": null,
+ "text": "// 126 for(auto d : desa) {"
+ },
+ {
+ "source": null,
+ "text": "// 127 printf(\"%d\\n\", d);"
+ },
+ {
+ "source": null,
+ "text": "// 128 }"
+ },
+ {
+ "source": null,
+ "text": "// 129 }"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes in section .bss"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .init_array"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .rodata"
+ },
+ {
+ "source": null,
+ "text": "// 260 bytes in section .text"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 110 bytes of CODE memory (+ 154 bytes shared)"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes of CONST memory"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes of DATA memory"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "//Errors: none"
+ },
+ {
+ "source": null,
+ "text": "//Warnings: none"
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.labels.comments.approved.txt b/test/filters-cases/ewarm-1.asm.directives.labels.comments.approved.txt
new file mode 100644
index 000000000..063389250
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.labels.comments.approved.txt
@@ -0,0 +1,969 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.labels.comments.json b/test/filters-cases/ewarm-1.asm.directives.labels.comments.json
new file mode 100644
index 000000000..3fada2acc
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.labels.comments.json
@@ -0,0 +1,1443 @@
+{
+ "asm": [
+ {
+ "text": " SECTION `.text`:CODE:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 114
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 114
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "__sti__routine:",
+ "source": null
+ },
+ {
+ "text": " PUSH {R7,LR}",
+ "source": {
+ "file": null,
+ "line": 114
+ }
+ },
+ {
+ "text": " LDR.N R0,??DataTable1_1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " POP {R0,PC} ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.bss`:DATA:REORDER:NOROOT(2)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DATA",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "desa:",
+ "source": null
+ },
+ {
+ "text": " DS8 68",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "main:",
+ "source": null
+ },
+ {
+ "text": " PUSH {R2-R4,LR}",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR.N R4,??DataTable1_1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R1,#+1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,R4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R1,#+2",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,R4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R1,#+3",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,R4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R1,#+4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,R4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,R4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " STR R0,[SP, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,R4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " STR R0,[SP, #+4]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " B.N ??main_0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "??main_1:",
+ "source": null
+ },
+ {
+ "text": " MOV R0,SP",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\"",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL printf",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOV R0,SP",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "??main_0:",
+ "source": null
+ },
+ {
+ "text": " ADD R1,SP,#+4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOV R0,SP",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " CMP R0,#+0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BNE.N ??main_1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " POP {R0,R1,R4,PC} ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:NOROOT(2)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_TYPE SHT_PROGBITS, 0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DATA",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "??DataTable1:",
+ "source": null
+ },
+ {
+ "text": " DATA8",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DC8 \"%d\\n\"",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:NOROOT(2)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_TYPE SHT_PROGBITS, 0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DATA",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "??DataTable1_1:",
+ "source": null
+ },
+ {
+ "text": " DATA32",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DC32 desa",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZNSt5arrayIiLj16EEixEj",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZNSt5arrayIiLj16EEixEj:",
+ "source": null
+ },
+ {
+ "text": " ADD R0,R0,R1, LSL #+2",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BX LR ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZNSt5arrayIiLj16EE4dataEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:",
+ "source": null
+ },
+ {
+ "text": " BX LR ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:",
+ "source": null
+ },
+ {
+ "text": " STR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BX LR ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:",
+ "source": null
+ },
+ {
+ "text": " LDR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADDS R1,R1,#+4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " STR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R0,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BX LR ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:",
+ "source": null
+ },
+ {
+ "text": " LDR R0,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R1,[R1, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " CMP R0,R1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BEQ.N `??operator!=_0`",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,#+1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " B.N `??operator!=_1`",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "`??operator!=_0`:",
+ "source": null
+ },
+ {
+ "text": " MOVS R0,#+0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "`??operator!=_1`:",
+ "source": null
+ },
+ {
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BX LR ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:",
+ "source": null
+ },
+ {
+ "text": " LDR R0,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BX LR ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:",
+ "source": null
+ },
+ {
+ "text": " PUSH {R7,LR}",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R1,R0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOV R0,SP",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R0,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " POP {R1,PC} ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:",
+ "source": null
+ },
+ {
+ "text": " PUSH {R7,LR}",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R1,R0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOV R0,SP",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R0,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " POP {R1,PC} ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:",
+ "source": null
+ },
+ {
+ "text": " PUSH {R7,LR}",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADDS R0,R0,#+4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " POP {R1,PC} ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EE11IteratorEndEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:",
+ "source": null
+ },
+ {
+ "text": " PUSH {R4,LR}",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R4,R0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADDS R0,R4,#+4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R1,[R4, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADD R0,R0,R1, LSL #+2",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADDS R0,R0,#+4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " POP {R4,PC} ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EEC1Ev",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:",
+ "source": null
+ },
+ {
+ "text": " MOVS R1,#-1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " STR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BX LR ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EE4PushEi",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " THUMB",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:",
+ "source": null
+ },
+ {
+ "text": " PUSH {R4,LR}",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R4,R1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADDS R1,R1,#+1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " CMP R1,#+16",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BCS.N ??Push_0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADDS R1,R1,#+1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " STR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " LDR R1,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " ADDS R0,R0,#+4",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " BL _ZNSt5arrayIiLj16EEixEj",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " STR R4,[R0, #+0]",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " MOVS R0,#+1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " B.N ??Push_1",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "??Push_0:",
+ "source": null
+ },
+ {
+ "text": " MOVS R0,#+0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": "??Push_1:",
+ "source": null
+ },
+ {
+ "text": " POP {R4,PC} ;; return",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.init_array`:CODE:ROOT(2)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_TYPE SHT_INIT_ARRAY, 0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DATA",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.iar_vfe_header`:DATA:NOALLOC:NOROOT(2)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " SECTION_TYPE SHT_PROGBITS, 0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DATA",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DC32 0",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ },
+ {
+ "text": " SECTION `.rodata`:CONST:REORDER:NOROOT(2)",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DATA",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": " DC8 \"%d\\012\"",
+ "source": {
+ "file": null,
+ "line": 116
+ }
+ },
+ {
+ "text": "",
+ "source": null
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.labels.comments.library.approved.txt b/test/filters-cases/ewarm-1.asm.directives.labels.comments.library.approved.txt
new file mode 100644
index 000000000..063389250
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.labels.comments.library.approved.txt
@@ -0,0 +1,969 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.labels.comments.library.dontMaskFilenames.approved.txt b/test/filters-cases/ewarm-1.asm.directives.labels.comments.library.dontMaskFilenames.approved.txt
new file mode 100644
index 000000000..063389250
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.labels.comments.library.dontMaskFilenames.approved.txt
@@ -0,0 +1,969 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.directives.library.approved.txt b/test/filters-cases/ewarm-1.asm.directives.library.approved.txt
new file mode 100644
index 000000000..8e27a595e
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.directives.library.approved.txt
@@ -0,0 +1,1757 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// IAR ANSI C/C++ Compiler V8.32.3.193/W32 for ARM 09/Oct/2020 12:40:07"
+ },
+ {
+ "source": null,
+ "text": "// Copyright 1999-2019 IAR Systems AB."
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// Cpu mode ="
+ },
+ {
+ "source": null,
+ "text": "// Endian = little"
+ },
+ {
+ "source": null,
+ "text": "// Source file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Command line ="
+ },
+ {
+ "source": null,
+ "text": "// -lB"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "// -o"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s.obj"
+ },
+ {
+ "source": null,
+ "text": "// --enable_restrict -IC:\\arm\\inc -IC:\\arm\\inc\\c -IC:\\arm\\inc\\cpp"
+ },
+ {
+ "source": null,
+ "text": "// --dlib_config C:\\arm\\inc\\c\\DLib_Config_Full.h --c++ -e"
+ },
+ {
+ "source": null,
+ "text": "// --no_exceptions --no_rtti --no_static_destruction --cpu Cortex-M4"
+ },
+ {
+ "source": null,
+ "text": "// --fpu VFPv4_sp --endian little --cpu_mode thumb"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Locale = C"
+ },
+ {
+ "source": null,
+ "text": "// List file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " #define SHT_PROGBITS 0x1"
+ },
+ {
+ "source": null,
+ "text": " #define SHT_INIT_ARRAY 0xe"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// 1 #include <array>"
+ },
+ {
+ "source": null,
+ "text": "// 2"
+ },
+ {
+ "source": null,
+ "text": "// 3 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 4"
+ },
+ {
+ "source": null,
+ "text": "// 5 template<class Derived, typename DataType>"
+ },
+ {
+ "source": null,
+ "text": "// 6 class Iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 7 public:"
+ },
+ {
+ "source": null,
+ "text": "// 8 Iterator() = default;"
+ },
+ {
+ "source": null,
+ "text": "// 9"
+ },
+ {
+ "source": null,
+ "text": "// 10 class iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 11 public:"
+ },
+ {
+ "source": null,
+ "text": "// 12 iterator(DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 13 inline iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 14 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 15 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 16 }"
+ },
+ {
+ "source": null,
+ "text": "// 17 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 18 inline DataType& operator*() { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 19"
+ },
+ {
+ "source": null,
+ "text": "// 20 private:"
+ },
+ {
+ "source": null,
+ "text": "// 21 DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 22 };"
+ },
+ {
+ "source": null,
+ "text": "// 23"
+ },
+ {
+ "source": null,
+ "text": "// 24 class const_iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 25 public:"
+ },
+ {
+ "source": null,
+ "text": "// 26 const_iterator(const DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 27 inline const_iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 28 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 29 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 30 }"
+ },
+ {
+ "source": null,
+ "text": "// 31 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 32 inline const DataType& operator*() const { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 33"
+ },
+ {
+ "source": null,
+ "text": "// 34 private:"
+ },
+ {
+ "source": null,
+ "text": "// 35 const DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 36 };"
+ },
+ {
+ "source": null,
+ "text": "// 37"
+ },
+ {
+ "source": null,
+ "text": "// 38 inline iterator begin() { return iterator((DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 39 inline iterator end() { return iterator((DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 40 inline const_iterator begin() const { return const_iterator((const DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 41 inline const_iterator end() const { return const_iterator((const DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 42 };"
+ },
+ {
+ "source": null,
+ "text": "// 43"
+ },
+ {
+ "source": null,
+ "text": "// 44 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 45"
+ },
+ {
+ "source": null,
+ "text": "// 46"
+ },
+ {
+ "source": null,
+ "text": "// 47 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 48 template<typename T, unsigned int MAX_SIZE>"
+ },
+ {
+ "source": null,
+ "text": "// 49 class FixedStack : public Iterator<FixedStack<T, MAX_SIZE>, T> {"
+ },
+ {
+ "source": null,
+ "text": "// 50 friend class Iterator<FixedStack<T, MAX_SIZE>, T>;"
+ },
+ {
+ "source": null,
+ "text": "// 51 inline constexpr auto IteratorBegin() { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 52 inline constexpr auto IteratorEnd() { return m_Stack.data() + m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 53"
+ },
+ {
+ "source": null,
+ "text": "// 54 public:"
+ },
+ {
+ "source": null,
+ "text": "// 55 FixedStack() : m_Pos(-1) {}"
+ },
+ {
+ "source": null,
+ "text": "// 56"
+ },
+ {
+ "source": null,
+ "text": "// 57 inline bool Push(T elem) {"
+ },
+ {
+ "source": null,
+ "text": "// 58 if ((m_Pos + 1) < MAX_SIZE) {"
+ },
+ {
+ "source": null,
+ "text": "// 59 m_Pos++;"
+ },
+ {
+ "source": null,
+ "text": "// 60 m_Stack[m_Pos] = elem;"
+ },
+ {
+ "source": null,
+ "text": "// 61 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 62 }"
+ },
+ {
+ "source": null,
+ "text": "// 63"
+ },
+ {
+ "source": null,
+ "text": "// 64 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 65 }"
+ },
+ {
+ "source": null,
+ "text": "// 66"
+ },
+ {
+ "source": null,
+ "text": "// 67 inline bool Pop(T replaceLast) {"
+ },
+ {
+ "source": null,
+ "text": "// 68 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 69 m_Stack[m_Pos--] = replaceLast;"
+ },
+ {
+ "source": null,
+ "text": "// 70 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 71 }"
+ },
+ {
+ "source": null,
+ "text": "// 72"
+ },
+ {
+ "source": null,
+ "text": "// 73 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 74 }"
+ },
+ {
+ "source": null,
+ "text": "// 75"
+ },
+ {
+ "source": null,
+ "text": "// 76 inline bool Pop() {"
+ },
+ {
+ "source": null,
+ "text": "// 77 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 78 m_Pos--;"
+ },
+ {
+ "source": null,
+ "text": "// 79 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 80 }"
+ },
+ {
+ "source": null,
+ "text": "// 81"
+ },
+ {
+ "source": null,
+ "text": "// 82 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 83 }"
+ },
+ {
+ "source": null,
+ "text": "// 84"
+ },
+ {
+ "source": null,
+ "text": "// 85 inline void Clear(T fill) {"
+ },
+ {
+ "source": null,
+ "text": "// 86 m_Pos = -1;"
+ },
+ {
+ "source": null,
+ "text": "// 87 m_Stack.fill(fill);"
+ },
+ {
+ "source": null,
+ "text": "// 88 }"
+ },
+ {
+ "source": null,
+ "text": "// 89"
+ },
+ {
+ "source": null,
+ "text": "// 90 inline void Clear() { m_Pos = -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 91"
+ },
+ {
+ "source": null,
+ "text": "// 92 inline int FreeSpace() { return (MAX_SIZE - (m_Pos + 1)); }"
+ },
+ {
+ "source": null,
+ "text": "// 93"
+ },
+ {
+ "source": null,
+ "text": "// 94 inline T* DataPtr() const { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 95"
+ },
+ {
+ "source": null,
+ "text": "// 96 inline int Size() const { return m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 97"
+ },
+ {
+ "source": null,
+ "text": "// 98 inline bool Full() { return Size() == MAX_SIZE; }"
+ },
+ {
+ "source": null,
+ "text": "// 99"
+ },
+ {
+ "source": null,
+ "text": "// 100 inline T& Top(int back = 0) {"
+ },
+ {
+ "source": null,
+ "text": "// 101 return m_Stack[m_Pos + back];"
+ },
+ {
+ "source": null,
+ "text": "// 102 }"
+ },
+ {
+ "source": null,
+ "text": "// 103"
+ },
+ {
+ "source": null,
+ "text": "// 104 inline bool Empty() const { return m_Pos == -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 105"
+ },
+ {
+ "source": null,
+ "text": "// 106 inline T& operator[](int index) { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 107 inline const T& operator[](int index) const { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 108"
+ },
+ {
+ "source": null,
+ "text": "// 109 private:"
+ },
+ {
+ "source": null,
+ "text": "// 110 int m_Pos;"
+ },
+ {
+ "source": null,
+ "text": "// 111 std::array<T, MAX_SIZE> m_Stack;"
+ },
+ {
+ "source": null,
+ "text": "// 112 };"
+ },
+ {
+ "source": null,
+ "text": "// 113"
+ },
+ {
+ "source": null,
+ "text": "// 114 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 115"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// static __intrinsic __interwork __softfp void __sti__routine()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": null,
+ "text": "// 116 NA::FixedStack<int, 16> desa;"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int & std::array<int, 16U>::operator[](size_t)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *std::array<int, 16U>::data()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::iterator(int *)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator++()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator!=(NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator const &) const"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int &NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator*()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::begin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::end()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorBegin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorEnd()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::FixedStack<int, 16U>::FixedStack()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::FixedStack<int, 16U>::Push(int)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// 117"
+ },
+ {
+ "source": null,
+ "text": "// 118 void main() {"
+ },
+ {
+ "source": null,
+ "text": "// 119"
+ },
+ {
+ "source": null,
+ "text": "// 120"
+ },
+ {
+ "source": null,
+ "text": "// 121 desa.Push(1);"
+ },
+ {
+ "source": null,
+ "text": "// 122 desa.Push(2);"
+ },
+ {
+ "source": null,
+ "text": "// 123 desa.Push(3);"
+ },
+ {
+ "source": null,
+ "text": "// 124 desa.Push(4);"
+ },
+ {
+ "source": null,
+ "text": "// 125"
+ },
+ {
+ "source": null,
+ "text": "// 126 for(auto d : desa) {"
+ },
+ {
+ "source": null,
+ "text": "// 127 printf(\"%d\\n\", d);"
+ },
+ {
+ "source": null,
+ "text": "// 128 }"
+ },
+ {
+ "source": null,
+ "text": "// 129 }"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes in section .bss"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .init_array"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .rodata"
+ },
+ {
+ "source": null,
+ "text": "// 260 bytes in section .text"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 110 bytes of CODE memory (+ 154 bytes shared)"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes of CONST memory"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes of DATA memory"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "//Errors: none"
+ },
+ {
+ "source": null,
+ "text": "//Warnings: none"
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.asm.none.approved.txt b/test/filters-cases/ewarm-1.asm.none.approved.txt
new file mode 100644
index 000000000..613783fc6
--- /dev/null
+++ b/test/filters-cases/ewarm-1.asm.none.approved.txt
@@ -0,0 +1,2077 @@
+{
+ "asm": [
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// IAR ANSI C/C++ Compiler V8.32.3.193/W32 for ARM 09/Oct/2020 12:40:07"
+ },
+ {
+ "source": null,
+ "text": "// Copyright 1999-2019 IAR Systems AB."
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// Cpu mode ="
+ },
+ {
+ "source": null,
+ "text": "// Endian = little"
+ },
+ {
+ "source": null,
+ "text": "// Source file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Command line ="
+ },
+ {
+ "source": null,
+ "text": "// -lB"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "// -o"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s.obj"
+ },
+ {
+ "source": null,
+ "text": "// --enable_restrict -IC:\\arm\\inc -IC:\\arm\\inc\\c -IC:\\arm\\inc\\cpp"
+ },
+ {
+ "source": null,
+ "text": "// --dlib_config C:\\arm\\inc\\c\\DLib_Config_Full.h --c++ -e"
+ },
+ {
+ "source": null,
+ "text": "// --no_exceptions --no_rtti --no_static_destruction --cpu Cortex-M4"
+ },
+ {
+ "source": null,
+ "text": "// --fpu VFPv4_sp --endian little --cpu_mode thumb"
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// Locale = C"
+ },
+ {
+ "source": null,
+ "text": "// List file ="
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\output.s"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "///////////////////////////////////////////////////////////////////////////////"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " #define SHT_PROGBITS 0x1"
+ },
+ {
+ "source": null,
+ "text": " #define SHT_INIT_ARRAY 0xe"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " EXTERN printf"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC desa"
+ },
+ {
+ "source": null,
+ "text": " PUBLIC main"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// C:\\Users\\NA_BUI~1\\AppData\\Local\\Temp\\compiler-explorer-compiler202099-14988-evjfs2.ood3c\\example.cpp"
+ },
+ {
+ "source": null,
+ "text": "// 1 #include <array>"
+ },
+ {
+ "source": null,
+ "text": "// 2"
+ },
+ {
+ "source": null,
+ "text": "// 3 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 4"
+ },
+ {
+ "source": null,
+ "text": "// 5 template<class Derived, typename DataType>"
+ },
+ {
+ "source": null,
+ "text": "// 6 class Iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 7 public:"
+ },
+ {
+ "source": null,
+ "text": "// 8 Iterator() = default;"
+ },
+ {
+ "source": null,
+ "text": "// 9"
+ },
+ {
+ "source": null,
+ "text": "// 10 class iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 11 public:"
+ },
+ {
+ "source": null,
+ "text": "// 12 iterator(DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 13 inline iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 14 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 15 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 16 }"
+ },
+ {
+ "source": null,
+ "text": "// 17 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 18 inline DataType& operator*() { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 19"
+ },
+ {
+ "source": null,
+ "text": "// 20 private:"
+ },
+ {
+ "source": null,
+ "text": "// 21 DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 22 };"
+ },
+ {
+ "source": null,
+ "text": "// 23"
+ },
+ {
+ "source": null,
+ "text": "// 24 class const_iterator {"
+ },
+ {
+ "source": null,
+ "text": "// 25 public:"
+ },
+ {
+ "source": null,
+ "text": "// 26 const_iterator(const DataType* ptr = nullptr) : ptr(ptr) {}"
+ },
+ {
+ "source": null,
+ "text": "// 27 inline const_iterator operator++() {"
+ },
+ {
+ "source": null,
+ "text": "// 28 ++ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 29 return *this;"
+ },
+ {
+ "source": null,
+ "text": "// 30 }"
+ },
+ {
+ "source": null,
+ "text": "// 31 inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 32 inline const DataType& operator*() const { return *ptr; }"
+ },
+ {
+ "source": null,
+ "text": "// 33"
+ },
+ {
+ "source": null,
+ "text": "// 34 private:"
+ },
+ {
+ "source": null,
+ "text": "// 35 const DataType* ptr;"
+ },
+ {
+ "source": null,
+ "text": "// 36 };"
+ },
+ {
+ "source": null,
+ "text": "// 37"
+ },
+ {
+ "source": null,
+ "text": "// 38 inline iterator begin() { return iterator((DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 39 inline iterator end() { return iterator((DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 40 inline const_iterator begin() const { return const_iterator((const DataType*)((Derived*)this)->IteratorBegin()); }"
+ },
+ {
+ "source": null,
+ "text": "// 41 inline const_iterator end() const { return const_iterator((const DataType*)((Derived*)this)->IteratorEnd()); }"
+ },
+ {
+ "source": null,
+ "text": "// 42 };"
+ },
+ {
+ "source": null,
+ "text": "// 43"
+ },
+ {
+ "source": null,
+ "text": "// 44 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 45"
+ },
+ {
+ "source": null,
+ "text": "// 46"
+ },
+ {
+ "source": null,
+ "text": "// 47 namespace NA {"
+ },
+ {
+ "source": null,
+ "text": "// 48 template<typename T, unsigned int MAX_SIZE>"
+ },
+ {
+ "source": null,
+ "text": "// 49 class FixedStack : public Iterator<FixedStack<T, MAX_SIZE>, T> {"
+ },
+ {
+ "source": null,
+ "text": "// 50 friend class Iterator<FixedStack<T, MAX_SIZE>, T>;"
+ },
+ {
+ "source": null,
+ "text": "// 51 inline constexpr auto IteratorBegin() { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 52 inline constexpr auto IteratorEnd() { return m_Stack.data() + m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 53"
+ },
+ {
+ "source": null,
+ "text": "// 54 public:"
+ },
+ {
+ "source": null,
+ "text": "// 55 FixedStack() : m_Pos(-1) {}"
+ },
+ {
+ "source": null,
+ "text": "// 56"
+ },
+ {
+ "source": null,
+ "text": "// 57 inline bool Push(T elem) {"
+ },
+ {
+ "source": null,
+ "text": "// 58 if ((m_Pos + 1) < MAX_SIZE) {"
+ },
+ {
+ "source": null,
+ "text": "// 59 m_Pos++;"
+ },
+ {
+ "source": null,
+ "text": "// 60 m_Stack[m_Pos] = elem;"
+ },
+ {
+ "source": null,
+ "text": "// 61 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 62 }"
+ },
+ {
+ "source": null,
+ "text": "// 63"
+ },
+ {
+ "source": null,
+ "text": "// 64 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 65 }"
+ },
+ {
+ "source": null,
+ "text": "// 66"
+ },
+ {
+ "source": null,
+ "text": "// 67 inline bool Pop(T replaceLast) {"
+ },
+ {
+ "source": null,
+ "text": "// 68 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 69 m_Stack[m_Pos--] = replaceLast;"
+ },
+ {
+ "source": null,
+ "text": "// 70 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 71 }"
+ },
+ {
+ "source": null,
+ "text": "// 72"
+ },
+ {
+ "source": null,
+ "text": "// 73 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 74 }"
+ },
+ {
+ "source": null,
+ "text": "// 75"
+ },
+ {
+ "source": null,
+ "text": "// 76 inline bool Pop() {"
+ },
+ {
+ "source": null,
+ "text": "// 77 if (m_Pos != -1) {"
+ },
+ {
+ "source": null,
+ "text": "// 78 m_Pos--;"
+ },
+ {
+ "source": null,
+ "text": "// 79 return true;"
+ },
+ {
+ "source": null,
+ "text": "// 80 }"
+ },
+ {
+ "source": null,
+ "text": "// 81"
+ },
+ {
+ "source": null,
+ "text": "// 82 return false;"
+ },
+ {
+ "source": null,
+ "text": "// 83 }"
+ },
+ {
+ "source": null,
+ "text": "// 84"
+ },
+ {
+ "source": null,
+ "text": "// 85 inline void Clear(T fill) {"
+ },
+ {
+ "source": null,
+ "text": "// 86 m_Pos = -1;"
+ },
+ {
+ "source": null,
+ "text": "// 87 m_Stack.fill(fill);"
+ },
+ {
+ "source": null,
+ "text": "// 88 }"
+ },
+ {
+ "source": null,
+ "text": "// 89"
+ },
+ {
+ "source": null,
+ "text": "// 90 inline void Clear() { m_Pos = -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 91"
+ },
+ {
+ "source": null,
+ "text": "// 92 inline int FreeSpace() { return (MAX_SIZE - (m_Pos + 1)); }"
+ },
+ {
+ "source": null,
+ "text": "// 93"
+ },
+ {
+ "source": null,
+ "text": "// 94 inline T* DataPtr() const { return m_Stack.data(); }"
+ },
+ {
+ "source": null,
+ "text": "// 95"
+ },
+ {
+ "source": null,
+ "text": "// 96 inline int Size() const { return m_Pos + 1; }"
+ },
+ {
+ "source": null,
+ "text": "// 97"
+ },
+ {
+ "source": null,
+ "text": "// 98 inline bool Full() { return Size() == MAX_SIZE; }"
+ },
+ {
+ "source": null,
+ "text": "// 99"
+ },
+ {
+ "source": null,
+ "text": "// 100 inline T& Top(int back = 0) {"
+ },
+ {
+ "source": null,
+ "text": "// 101 return m_Stack[m_Pos + back];"
+ },
+ {
+ "source": null,
+ "text": "// 102 }"
+ },
+ {
+ "source": null,
+ "text": "// 103"
+ },
+ {
+ "source": null,
+ "text": "// 104 inline bool Empty() const { return m_Pos == -1; }"
+ },
+ {
+ "source": null,
+ "text": "// 105"
+ },
+ {
+ "source": null,
+ "text": "// 106 inline T& operator[](int index) { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 107 inline const T& operator[](int index) const { return m_Stack[index]; }"
+ },
+ {
+ "source": null,
+ "text": "// 108"
+ },
+ {
+ "source": null,
+ "text": "// 109 private:"
+ },
+ {
+ "source": null,
+ "text": "// 110 int m_Pos;"
+ },
+ {
+ "source": null,
+ "text": "// 111 std::array<T, MAX_SIZE> m_Stack;"
+ },
+ {
+ "source": null,
+ "text": "// 112 };"
+ },
+ {
+ "source": null,
+ "text": "// 113"
+ },
+ {
+ "source": null,
+ "text": "// 114 } // namespace NA"
+ },
+ {
+ "source": null,
+ "text": "// 115"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// static __intrinsic __interwork __softfp void __sti__routine()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "__sti__routine:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 114
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": null,
+ "text": "// 116 NA::FixedStack<int, 16> desa;"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R0,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.bss`:DATA:REORDER:NOROOT(2)"
+ },
+ {
+ "source": null,
+ "text": " DATA"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "desa:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DS8 68"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "main:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R2-R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR.N R4,??DataTable1_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+3"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,R4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R0,[SP, #+4]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??main_0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADR.N R0,??DataTable1 ;; \"%d\\n\""
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL printf"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??main_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R1,SP,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,#+0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BNE.N ??main_1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R0,R1,R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:NOROOT(2)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_TYPE SHT_PROGBITS, 0"
+ },
+ {
+ "source": null,
+ "text": " DATA"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1:"
+ },
+ {
+ "source": null,
+ "text": " DATA8"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\n\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:NOROOT(2)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_TYPE SHT_PROGBITS, 0"
+ },
+ {
+ "source": null,
+ "text": " DATA"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??DataTable1_1:"
+ },
+ {
+ "source": null,
+ "text": " DATA32"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 desa"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int & std::array<int, 16U>::operator[](size_t)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EEixEj:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *std::array<int, 16U>::data()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNSt5arrayIiLj16EE4dataEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::iterator(int *)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator++()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorppEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator!=(NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator const &) const"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZNK2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorneERKS4_:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R1, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R0,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BEQ.N `??operator!=_0`"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N `??operator!=_1`"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_0`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": "`??operator!=_1`:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " UXTB R0,R0 ;; ZeroExt R0,R0,#+24,#+24"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int &NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator::operator*()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratordeEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::begin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE5beginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp NA::Iterator<NA::FixedStack<int, 16U>, int>::iterator NA::Iterator<NA::FixedStack<int, 16U>, int>::end()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE3endEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOV R0,SP"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZN2NA8IteratorINS_10FixedStackIiLj16EEEiE8iteratorC1EPi"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R0,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EE13IteratorBeginEv"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorBegin()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE13IteratorBeginEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R7,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R1,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EE11IteratorEndEv"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp int *NA::FixedStack<int, 16U>::IteratorEnd()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE11IteratorEndEv:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R4,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EE4dataEv"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R4, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADD R0,R0,R1, LSL #+2"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EEC1Ev"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __code __interwork __softfp NA::FixedStack<int, 16U>::FixedStack()"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EEC1Ev:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R1,#-1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BX LR ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.text`:CODE:REORDER:NOROOT(1)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_GROUP _ZN2NA10FixedStackIiLj16EE4PushEi"
+ },
+ {
+ "source": null,
+ "text": " THUMB"
+ },
+ {
+ "source": null,
+ "text": "// __interwork __softfp bool NA::FixedStack<int, 16U>::Push(int)"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "_ZN2NA10FixedStackIiLj16EE4PushEi:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " PUSH {R4,LR}"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R4,R1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " CMP R1,#+16"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BCS.N ??Push_0"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R1,R1,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " LDR R1,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " ADDS R0,R0,#+4"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " BL _ZNSt5arrayIiLj16EEixEj"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " STR R4,[R0, #+0]"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+1"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " B.N ??Push_1"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_0:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " MOVS R0,#+0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "??Push_1:"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " POP {R4,PC} ;; return"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.init_array`:CODE:ROOT(2)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_TYPE SHT_INIT_ARRAY, 0"
+ },
+ {
+ "source": null,
+ "text": " DATA"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 RELOC_ARM_TARGET1 __sti__routine"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.iar_vfe_header`:DATA:NOALLOC:NOROOT(2)"
+ },
+ {
+ "source": null,
+ "text": " SECTION_TYPE SHT_PROGBITS, 0"
+ },
+ {
+ "source": null,
+ "text": " DATA"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC32 0"
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": " SECTION `.rodata`:CONST:REORDER:NOROOT(2)"
+ },
+ {
+ "source": null,
+ "text": " DATA"
+ },
+ {
+ "source": {
+ "file": null,
+ "line": 116
+ },
+ "text": " DC8 \"%d\\012\""
+ },
+ {
+ "source": null,
+ "text": ""
+ },
+ {
+ "source": null,
+ "text": "// 117"
+ },
+ {
+ "source": null,
+ "text": "// 118 void main() {"
+ },
+ {
+ "source": null,
+ "text": "// 119"
+ },
+ {
+ "source": null,
+ "text": "// 120"
+ },
+ {
+ "source": null,
+ "text": "// 121 desa.Push(1);"
+ },
+ {
+ "source": null,
+ "text": "// 122 desa.Push(2);"
+ },
+ {
+ "source": null,
+ "text": "// 123 desa.Push(3);"
+ },
+ {
+ "source": null,
+ "text": "// 124 desa.Push(4);"
+ },
+ {
+ "source": null,
+ "text": "// 125"
+ },
+ {
+ "source": null,
+ "text": "// 126 for(auto d : desa) {"
+ },
+ {
+ "source": null,
+ "text": "// 127 printf(\"%d\\n\", d);"
+ },
+ {
+ "source": null,
+ "text": "// 128 }"
+ },
+ {
+ "source": null,
+ "text": "// 129 }"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes in section .bss"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .init_array"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes in section .rodata"
+ },
+ {
+ "source": null,
+ "text": "// 260 bytes in section .text"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "// 110 bytes of CODE memory (+ 154 bytes shared)"
+ },
+ {
+ "source": null,
+ "text": "// 4 bytes of CONST memory"
+ },
+ {
+ "source": null,
+ "text": "// 68 bytes of DATA memory"
+ },
+ {
+ "source": null,
+ "text": "//"
+ },
+ {
+ "source": null,
+ "text": "//Errors: none"
+ },
+ {
+ "source": null,
+ "text": "//Warnings: none"
+ },
+ {
+ "source": null,
+ "text": " END"
+ }
+ ]
+}
diff --git a/test/filters-cases/ewarm-1.cpp b/test/filters-cases/ewarm-1.cpp
new file mode 100644
index 000000000..08fe0ea3f
--- /dev/null
+++ b/test/filters-cases/ewarm-1.cpp
@@ -0,0 +1,129 @@
+#include <array>
+
+namespace NA {
+
+ template<class Derived, typename DataType>
+ class Iterator {
+ public:
+ Iterator() = default;
+
+ class iterator {
+ public:
+ iterator(DataType* ptr = nullptr) : ptr(ptr) {}
+ inline iterator operator++() {
+ ++ptr;
+ return *this;
+ }
+ inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }
+ inline DataType& operator*() { return *ptr; }
+
+ private:
+ DataType* ptr;
+ };
+
+ class const_iterator {
+ public:
+ const_iterator(const DataType* ptr = nullptr) : ptr(ptr) {}
+ inline const_iterator operator++() {
+ ++ptr;
+ return *this;
+ }
+ inline bool operator!=(const iterator& other) const { return ptr != other.ptr; }
+ inline const DataType& operator*() const { return *ptr; }
+
+ private:
+ const DataType* ptr;
+ };
+
+ inline iterator begin() { return iterator((DataType*)((Derived*)this)->IteratorBegin()); }
+ inline iterator end() { return iterator((DataType*)((Derived*)this)->IteratorEnd()); }
+ inline const_iterator begin() const { return const_iterator((const DataType*)((Derived*)this)->IteratorBegin()); }
+ inline const_iterator end() const { return const_iterator((const DataType*)((Derived*)this)->IteratorEnd()); }
+ };
+
+} // namespace NA
+
+
+namespace NA {
+ template<typename T, unsigned int MAX_SIZE>
+ class FixedStack : public Iterator<FixedStack<T, MAX_SIZE>, T> {
+ friend class Iterator<FixedStack<T, MAX_SIZE>, T>;
+ inline constexpr auto IteratorBegin() { return m_Stack.data(); }
+ inline constexpr auto IteratorEnd() { return m_Stack.data() + m_Pos + 1; }
+
+ public:
+ FixedStack() : m_Pos(-1) {}
+
+ inline bool Push(T elem) {
+ if ((m_Pos + 1) < MAX_SIZE) {
+ m_Pos++;
+ m_Stack[m_Pos] = elem;
+ return true;
+ }
+
+ return false;
+ }
+
+ inline bool Pop(T replaceLast) {
+ if (m_Pos != -1) {
+ m_Stack[m_Pos--] = replaceLast;
+ return true;
+ }
+
+ return false;
+ }
+
+ inline bool Pop() {
+ if (m_Pos != -1) {
+ m_Pos--;
+ return true;
+ }
+
+ return false;
+ }
+
+ inline void Clear(T fill) {
+ m_Pos = -1;
+ m_Stack.fill(fill);
+ }
+
+ inline void Clear() { m_Pos = -1; }
+
+ inline int FreeSpace() { return (MAX_SIZE - (m_Pos + 1)); }
+
+ inline T* DataPtr() const { return m_Stack.data(); }
+
+ inline int Size() const { return m_Pos + 1; }
+
+ inline bool Full() { return Size() == MAX_SIZE; }
+
+ inline T& Top(int back = 0) {
+ return m_Stack[m_Pos + back];
+ }
+
+ inline bool Empty() const { return m_Pos == -1; }
+
+ inline T& operator[](int index) { return m_Stack[index]; }
+ inline const T& operator[](int index) const { return m_Stack[index]; }
+
+ private:
+ int m_Pos;
+ std::array<T, MAX_SIZE> m_Stack;
+ };
+
+} // namespace NA
+
+NA::FixedStack<int, 16> desa;
+
+void main() {
+
+
+ desa.Push(1);
+ desa.Push(2);
+ desa.Push(3);
+ desa.Push(4);
+
+ for(auto d : desa) {
+ printf("%d\n", d);
+ }
+} \ No newline at end of file