Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // parameters.cc -- general parameters for a link using gold | 1 // parameters.cc -- general parameters for a link using gold |
| 2 | 2 |
| 3 // Copyright 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. | 3 // Copyright 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. |
| 4 // Written by Ian Lance Taylor <iant@google.com>. | 4 // Written by Ian Lance Taylor <iant@google.com>. |
| 5 | 5 |
| 6 // This file is part of gold. | 6 // This file is part of gold. |
| 7 | 7 |
| 8 // This program is free software; you can redistribute it and/or modify | 8 // This program is free software; you can redistribute it and/or modify |
| 9 // it under the terms of the GNU General Public License as published by | 9 // it under the terms of the GNU General Public License as published by |
| 10 // the Free Software Foundation; either version 3 of the License, or | 10 // the Free Software Foundation; either version 3 of the License, or |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 219 } | 219 } |
| 220 | 220 |
| 221 // Return the name of the entry symbol. | 221 // Return the name of the entry symbol. |
| 222 | 222 |
| 223 const char* | 223 const char* |
| 224 Parameters::entry() const | 224 Parameters::entry() const |
| 225 { | 225 { |
| 226 const char* ret = this->options().entry(); | 226 const char* ret = this->options().entry(); |
| 227 if (ret == NULL) | 227 if (ret == NULL) |
| 228 { | 228 { |
| 229 if(this->target().machine_code() == elfcpp::EM_MIPS) | |
|
robertm
2012/04/27 19:46:15
FYI: this will likely not work with pnacl
Aleksandar Simeonov
2012/05/08 15:21:42
MIPS has __start as default entry symbol (other ar
| |
| 230 ret = "__start"; | |
| 231 else | |
| 229 // FIXME: Need to support target specific entry symbol. | 232 // FIXME: Need to support target specific entry symbol. |
| 230 ret = "_start"; | 233 » ret = "_start"; |
| 231 } | 234 } |
| 232 return ret; | 235 return ret; |
| 233 } | 236 } |
| 234 | 237 |
| 235 // Set the incremental linking mode to INCREMENTAL_FULL. Used when | 238 // Set the incremental linking mode to INCREMENTAL_FULL. Used when |
| 236 // the linker determines that an incremental update is not possible. | 239 // the linker determines that an incremental update is not possible. |
| 237 // Returns false if the incremental mode was INCREMENTAL_UPDATE, | 240 // Returns false if the incremental mode was INCREMENTAL_UPDATE, |
| 238 // indicating that the linker should exit if an update is not possible. | 241 // indicating that the linker should exit if an update is not possible. |
| 239 | 242 |
| 240 bool | 243 bool |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 369 | 372 |
| 370 // Clear the current target, for testing. | 373 // Clear the current target, for testing. |
| 371 | 374 |
| 372 void | 375 void |
| 373 parameters_clear_target() | 376 parameters_clear_target() |
| 374 { | 377 { |
| 375 static_parameters.clear_target(); | 378 static_parameters.clear_target(); |
| 376 } | 379 } |
| 377 | 380 |
| 378 } // End namespace gold. | 381 } // End namespace gold. |
| OLD | NEW |