OSDN Git Service

[Hexagon] Use addAliasForDirective for data directives
authorAlex Bradbury <asb@lowrisc.org>
Thu, 17 May 2018 13:21:18 +0000 (13:21 +0000)
committerAlex Bradbury <asb@lowrisc.org>
Thu, 17 May 2018 13:21:18 +0000 (13:21 +0000)
commitefebb47c70497fcb0e1e2b462e0827a4878bc079
tree10ea5449f6fc850d9253bd11dad5b73b6cea5577
parent87225e582ec29b47b3d78f643382ec7354364f94
[Hexagon] Use addAliasForDirective for data directives

Data directives such as .word, .half, .hword are currently parsed using
HexagonAsmParser::ParseDirectiveValue which effectively duplicates logic from
AsmParser::parseDirectiveValue. This patch deletes that duplicated logic in
favour of using addAliasForDirective.

Differential Revision: https://reviews.llvm.org/D46999

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@332607 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/Hexagon/AsmParser/HexagonAsmParser.cpp
test/MC/Hexagon/data-directives-invalid.s [new file with mode: 0644]
test/MC/Hexagon/data-directives-valid.s [new file with mode: 0644]