summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/avremu/test-suite/string.c
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
committerNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
commite0c6872cf40896c7be36b11dcc744620f10adf1d (patch)
tree60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/latex/contrib/avremu/test-suite/string.c
Initial commit
Diffstat (limited to 'macros/latex/contrib/avremu/test-suite/string.c')
-rw-r--r--macros/latex/contrib/avremu/test-suite/string.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/macros/latex/contrib/avremu/test-suite/string.c b/macros/latex/contrib/avremu/test-suite/string.c
new file mode 100644
index 0000000000..616598884e
--- /dev/null
+++ b/macros/latex/contrib/avremu/test-suite/string.c
@@ -0,0 +1,22 @@
+#include <avr/io.h>
+
+// Produces LPM operations
+const char *foo = "abc";
+
+int main() {
+ char* p = foo;
+ while (*p) {
+ UDR = *p++;
+ }
+
+ asm volatile ("break");
+}
+
+/*
+ check-name: String Operations
+ check-start:
+ \avr@instr@stepn{1000000}
+
+ \avr@test@UDR{abc}
+ check-end:
+*/