[llvm] r279921 - [X86] Don't allow DR8-DR15 to be assembled in 32-bit mode. Add missing test for CR8-CR15.
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Sat Aug 27 10:13:35 PDT 2016
Author: ctopper
Date: Sat Aug 27 12:13:34 2016
New Revision: 279921
URL: http://llvm.org/viewvc/llvm-project?rev=279921&view=rev
Log:
[X86] Don't allow DR8-DR15 to be assembled in 32-bit mode. Add missing test for CR8-CR15.
Modified:
llvm/trunk/lib/Target/X86/MCTargetDesc/X86BaseInfo.h
llvm/trunk/test/MC/X86/x86_errors.s
Modified: llvm/trunk/lib/Target/X86/MCTargetDesc/X86BaseInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/MCTargetDesc/X86BaseInfo.h?rev=279921&r1=279920&r2=279921&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/MCTargetDesc/X86BaseInfo.h (original)
+++ llvm/trunk/lib/Target/X86/MCTargetDesc/X86BaseInfo.h Sat Aug 27 12:13:34 2016
@@ -750,6 +750,8 @@ namespace X86II {
case X86::R12B: case X86::R13B: case X86::R14B: case X86::R15B:
case X86::CR8: case X86::CR9: case X86::CR10: case X86::CR11:
case X86::CR12: case X86::CR13: case X86::CR14: case X86::CR15:
+ case X86::DR8: case X86::DR9: case X86::DR10: case X86::DR11:
+ case X86::DR12: case X86::DR13: case X86::DR14: case X86::DR15:
return true;
}
return false;
Modified: llvm/trunk/test/MC/X86/x86_errors.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/X86/x86_errors.s?rev=279921&r1=279920&r2=279921&view=diff
==============================================================================
--- llvm/trunk/test/MC/X86/x86_errors.s (original)
+++ llvm/trunk/test/MC/X86/x86_errors.s Sat Aug 27 12:13:34 2016
@@ -68,3 +68,9 @@ jrcxz 1
// 64: error: instruction requires: Not 64-bit mode
jcxz 1
+
+// 32: error: register %cr8 is only available in 64-bit mode
+movl %edx, %cr8
+
+// 32: error: register %dr8 is only available in 64-bit mode
+movl %edx, %dr8
More information about the llvm-commits
mailing list