From c6aad1560b840eeb81c0f72a2b3c9695246429f9 Mon Sep 17 00:00:00 2001 From: Andre Vieira Date: Tue, 13 Feb 2018 11:46:38 +0000 Subject: [PATCH] [ARM] Don't print "Requires NEON" error message for M-profile Differential Revision: https://reviews.llvm.org/D43125 llvm-svn: 325000 --- lib/Target/ARM/AsmParser/ARMAsmParser.cpp | 2 ++ test/MC/ARM/vfp4.s | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/Target/ARM/AsmParser/ARMAsmParser.cpp b/lib/Target/ARM/AsmParser/ARMAsmParser.cpp index 3d251887883..597d654bed9 100644 --- a/lib/Target/ARM/AsmParser/ARMAsmParser.cpp +++ b/lib/Target/ARM/AsmParser/ARMAsmParser.cpp @@ -10230,6 +10230,8 @@ ARMAsmParser::FilterNearMisses(SmallVectorImpl &NearMissesIn, if (!isThumb() && (MissingFeatures & Feature_IsThumb2) && (MissingFeatures & ~(Feature_IsThumb2 | Feature_IsThumb))) break; + if (isMClass() && (MissingFeatures & Feature_HasNEON)) + break; NearMissMessage Message; Message.Loc = IDLoc; diff --git a/test/MC/ARM/vfp4.s b/test/MC/ARM/vfp4.s index be36abe15d3..37d03bb53de 100644 --- a/test/MC/ARM/vfp4.s +++ b/test/MC/ARM/vfp4.s @@ -23,7 +23,7 @@ vfma.f32 d16, d18, d17 @ ARM: vfma.f32 q2, q4, q0 @ encoding: [0x50,0x4c,0x08,0xf2] @ THUMB: vfma.f32 q2, q4, q0 @ encoding: [0x08,0xef,0x50,0x4c] -@ THUMB_V7EM-ERRORS: error: instruction requires: NEON +@ THUMB_V7EM-ERRORS: error: invalid instruction @ THUMB_V7EM-ERRORS-NEXT: vfma.f32 q2, q4, q0 vfma.f32 q2, q4, q0 @@ -57,7 +57,7 @@ vfms.f32 d16, d18, d17 @ ARM: vfms.f32 q2, q4, q0 @ encoding: [0x50,0x4c,0x28,0xf2] @ THUMB: vfms.f32 q2, q4, q0 @ encoding: [0x28,0xef,0x50,0x4c] -@ THUMB_V7EM-ERRORS: error: instruction requires: NEON +@ THUMB_V7EM-ERRORS: error: invalid instruction @ THUMB_V7EM-ERRORS-NEXT: vfms.f32 q2, q4, q0 vfms.f32 q2, q4, q0