summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorDylan McKay <me@dylanmckay.io>2017-09-27 22:15:50 +0000
committerDylan McKay <me@dylanmckay.io>2017-09-27 22:15:50 +0000
commitbc9510e749714e70ea96ee4feabdd476e55124e5 (patch)
tree3ec5a0cf5ea8ba602280f35d0f672ac38c7f66ce /test
parent164431e6002980a98c4cdf3df03e1698f7fc7d58 (diff)
Merging r312905:
------------------------------------------------------------------------ r312905 | dylanmckay | 2017-09-11 22:32:51 +1200 (Mon, 11 Sep 2017) | 10 lines [AVR] Enable the '__do_copy_data' function Also enables '__do_clear_bss'. These functions are automaticalled called by the CRT if they are declared. We need these to be called otherwise RAM will start completely uninitialised, even though we need to copy RAM variables from progmem to RAM. ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_50@314356 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/CodeGen/AVR/clear-bss.ll5
-rw-r--r--test/CodeGen/AVR/copy-data-to-ram.ll5
2 files changed, 10 insertions, 0 deletions
diff --git a/test/CodeGen/AVR/clear-bss.ll b/test/CodeGen/AVR/clear-bss.ll
new file mode 100644
index 000000000000..9c63815c098d
--- /dev/null
+++ b/test/CodeGen/AVR/clear-bss.ll
@@ -0,0 +1,5 @@
+; RUN: llc < %s -march=avr | FileCheck %s
+
+; CHECK: .globl __do_clear_bss
+@zeroed = internal constant [3 x i8] zeroinitializer
+
diff --git a/test/CodeGen/AVR/copy-data-to-ram.ll b/test/CodeGen/AVR/copy-data-to-ram.ll
new file mode 100644
index 000000000000..021cc0f1a7f4
--- /dev/null
+++ b/test/CodeGen/AVR/copy-data-to-ram.ll
@@ -0,0 +1,5 @@
+; RUN: llc < %s -march=avr | FileCheck %s
+
+; CHECK: .globl __do_copy_data
+@str = internal global [3 x i8] c"foo"
+