aboutsummaryrefslogtreecommitdiff
path: root/gold/options.h
diff options
context:
space:
mode:
authorDoug Kwan <dougkwan@google.com>2010-01-22 19:43:00 +0000
committerDoug Kwan <dougkwan@google.com>2010-01-22 19:43:00 +0000
commit9b2fd367561081579a4ee270a6de58d3de910631 (patch)
treebe48b08ad6f41b699ec61ddc9ded68fa7924c79e /gold/options.h
parent80d0d023f5c6b8fdd7bb3e468acedb9c9e80413d (diff)
downloadgdb-9b2fd367561081579a4ee270a6de58d3de910631.zip
gdb-9b2fd367561081579a4ee270a6de58d3de910631.tar.gz
gdb-9b2fd367561081579a4ee270a6de58d3de910631.tar.bz2
2010-01-22 Viktor Kutuzov <vkutuzov@accesssoftek.com>
* gold/arm.cc (Target_arm): Updated fix_v4bx method and usage of Fix_v4bx enum values . * gold/options.h (General_options): New option definitions. (General_options::fix_v4bx): New method. (General_options::Fix_v4bx): New enum. * gold/options.cc (General_options::parse_fix_v4bx): New method. (General_options::parse_fix_v4bx_interworking): New method.
Diffstat (limited to 'gold/options.h')
-rw-r--r--gold/options.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/gold/options.h b/gold/options.h
index c13601c..22662db 100644
--- a/gold/options.h
+++ b/gold/options.h
@@ -726,6 +726,15 @@ class General_options
N_("(ARM only) Fix binaries for Cortex-A8 erratum."),
N_("(ARM only) Do not fix binaries for Cortex-A8 erratum."));
+ DEFINE_special(fix_v4bx, options::TWO_DASHES, '\0',
+ N_("(ARM only) Rewrite BX rn as MOV pc, rn for ARMv4"),
+ NULL);
+
+ DEFINE_special(fix_v4bx_interworking, options::TWO_DASHES, '\0',
+ N_("(ARM only) Rewrite BX rn branch to ARMv4 interworking "
+ "veneer"),
+ NULL);
+
DEFINE_bool(g, options::EXACTLY_ONE_DASH, '\0', false,
N_("Ignored"), NULL);
@@ -1218,6 +1227,20 @@ class General_options
bool
section_start(const char* secname, uint64_t* paddr) const;
+ enum Fix_v4bx
+ {
+ // Leave original instruction.
+ FIX_V4BX_NONE,
+ // Replace instruction.
+ FIX_V4BX_REPLACE,
+ // Generate an interworking veneer.
+ FIX_V4BX_INTERWORKING
+ };
+
+ Fix_v4bx
+ fix_v4bx() const
+ { return (this->fix_v4bx_); }
+
private:
// Don't copy this structure.
General_options(const General_options&);
@@ -1307,6 +1330,8 @@ class General_options
Unordered_set<std::string> symbols_to_retain_;
// Map from section name to address from --section-start.
std::map<std::string, uint64_t> section_starts_;
+ // Whether to process armv4 bx instruction relocation.
+ Fix_v4bx fix_v4bx_;
};
// The position-dependent options. We use this to store the state of