зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1605537 - override optimization settings for wasm compilation; r=firefox-build-system-reviewers,rstewart
The optimization flags that may have been chosen for our target compiler are not necessarily appropriate for our wasm compiler. Differential Revision: https://phabricator.services.mozilla.com/D58070 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
393e8a2296
Коммит
6005490cac
|
@ -611,6 +611,16 @@ class WasmFlags(TargetCompileFlags):
|
|||
|
||||
TargetCompileFlags.__init__(self, context)
|
||||
|
||||
def _optimize_flags(self):
|
||||
if not self._context.config.substs.get('MOZ_OPTIMIZE'):
|
||||
return []
|
||||
|
||||
# We don't want `MOZ_{PGO_,}OPTIMIZE_FLAGS here because they may contain
|
||||
# optimization flags that aren't suitable for wasm (e.g. -freorder-blocks).
|
||||
# Just optimize for size in all cases; we may want to make this
|
||||
# configurable.
|
||||
return ['-Os']
|
||||
|
||||
|
||||
class FinalTargetValue(ContextDerivedValue, six.text_type):
|
||||
def __new__(cls, context, value=""):
|
||||
|
|
Загрузка…
Ссылка в новой задаче