summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/AMDGPU
diff options
context:
space:
mode:
authorJan Vesely <jan.vesely@rutgers.edu>2018-05-31 04:08:08 +0000
committerJan Vesely <jan.vesely@rutgers.edu>2018-05-31 04:08:08 +0000
commitf5016b79a6aea6bde8ba1d99f5cc1627f03f2d54 (patch)
tree70b391130b03e669e6b8dcc1d9a7ec0e3e745a90 /llvm/lib/Target/AMDGPU
parentce27773a8ebcdb58c9b946497c2410fe622ccdb7 (diff)
downloadbcm5719-llvm-f5016b79a6aea6bde8ba1d99f5cc1627f03f2d54.tar.gz
bcm5719-llvm-f5016b79a6aea6bde8ba1d99f5cc1627f03f2d54.zip
AMDGPU/R600: Make sure functions are cacheline aligned
v2: use "ensureAlignment" make functions cache line aligned Fixes GPU hangs since r333219: "AMDGPU: Split R600 AsmPrinter code into its own class" Differential Revision: https://reviews.llvm.org/D47516 llvm-svn: 333622
Diffstat (limited to 'llvm/lib/Target/AMDGPU')
-rw-r--r--llvm/lib/Target/AMDGPU/R600AsmPrinter.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/lib/Target/AMDGPU/R600AsmPrinter.cpp b/llvm/lib/Target/AMDGPU/R600AsmPrinter.cpp
index 37ecbf7a869..ea247a07329 100644
--- a/llvm/lib/Target/AMDGPU/R600AsmPrinter.cpp
+++ b/llvm/lib/Target/AMDGPU/R600AsmPrinter.cpp
@@ -103,6 +103,10 @@ void R600AsmPrinter::EmitProgramInfoR600(const MachineFunction &MF) {
bool R600AsmPrinter::runOnMachineFunction(MachineFunction &MF) {
+
+ // Functions needs to be cacheline (256B) aligned.
+ MF.ensureAlignment(8);
+
SetupMachineFunction(MF);
MCContext &Context = getObjFileLowering().getContext();
OpenPOWER on IntegriCloud