aboutsummaryrefslogtreecommitdiffstats
path: root/lib/hipe
AgeCommit message (Collapse)Author
2016-10-06dialyzer: Fix opaque bugHans Bolinder
The "decoration" of opaque types works better than before when opaque types are used by other opaque types.
2016-10-06dialyzer: Fix opaque bugsHans Bolinder
t_from_form() sometimes returned a more general type than it should have done due to a bug in from_form_loop(): it stopped when the limit was exceeded, which could mean a collapsed type. Returning a type with smaller depth should fix this. is_specialization() now handles opaque types before unions, which should fix another problem. The bugs reported by Kostis.
2016-09-20Prepare releaseErlang/OTP
2016-09-12Merge branch 'margnus1/dialyzer/fix_maps_opaque/ERL-249/PR-1161/OTP-13878' ↵Hans Bolinder
into maint * margnus1/dialyzer/fix_maps_opaque/ERL-249/PR-1161/OTP-13878: erl_bif_types: Properly unopaque maps:merge/2 args
2016-09-07erl_bif_types: Properly unopaque maps:merge/2 argsMagnus Lång
erl_bif_types:type/5 was calling erl_types:map_pairwise_merge/3 directly with its (potentially opaque) arguments, causing Dialyzer crashes. Bug (ERL-249) reported and minimised test case provided by Felipe Ripoll.
2016-09-05hipe: Fix erl_types opaque match orderBjörn-Egil Dahlberg
2016-09-02Merge branch 'sverker/hipe-sparc-19/PR-1148/OTP-13861' into maintSverker Eriksson
* sverker/hipe-sparc-19/PR-1148: Eliminate catch-all clause from two functions Increase the time limit used by the test suite
2016-08-31dialyzer: Optimize an opaque type caseHans Bolinder
Fix a mistake in commit 85f6fe3b. Instead of using the declared opaque type, the form's type is used in a case where the opaque type is turned into a non-opaque type. The result is more general types (smaller Erlang terms) and faster analyses.
2016-08-26Eliminate catch-all clause from two functionsKostis Sagonas
A stronger version of Dialyzer complained that some case clauses in functions xaluop_is_shift/1 and xaluop_normalise/1 are unreachable. These clauses are now commented out. While at it, I thought that it would be better to eliminate the catch-all clauses in order to be certain we properly handle all RTL instructions that are used as inputs to these functions. Note: The code will now crash if there are unhandled cases.
2016-08-25Increase the time limit used by the test suiteKostis Sagonas
This is required in some really old SPARC machines running Solaris we still have access to.
2016-08-22hipe: Fix amd64 SSE2 encoding crashMagnus Lång
Register allocation could transform something like fmove u32, d99 to fmove $rdx, 0x20($rsp) which is an invalid instruction.
2016-08-22hipe: Fix tailcall stackarg clobber bugMagnus Lång
Since the link register/return address is restored before stack arguments are stored to the frame, we must not use it to store a stack argument. We do that by adding it to the registers clobbered by pseudo_tailcall_prepare.
2016-08-22hipe_arm: Fix translation of shift by 0Magnus Lång
The problem was caused by shift-by-immediate-zero, which wraps to immediate-32 with some shiftops. TODO: Someplace should be modified to crash when these are generated so debugging further instances of this gets easier in the future.
2016-08-22hipe_ppc: Fix PPC64 bug encoding large immediatesMagnus Lång
2016-08-22hipe_ppc: Fix incorrect encoding of shift by 0Magnus Lång
2016-08-22hipe_x86: Fix illegal inst from peephole optMagnus Lång
2016-06-28erl_types: Normalise X:=none() pairs in t_map/3Magnus Lång
t_map/3 previously required callers to perform this normalisation, but as t_from_form/5 would sometimes fail to do so, this requirement is relaxed. Bug (ERL-177) reported and shrunk by Luke Imhoff.
2016-06-21Prepare releaseErlang/OTP
2016-06-15hipe: Pattern matching compilation of binaries and bistringsKostis Sagonas
The Core Erlang pattern matching compiler was written long ago, at a time when binaries and bistrings did not really exist in Erlang. This patch, taken from the code of CutEr where it's used for more than a year now, extends the transformation for pattern matching compilation to also include binaries and bistrings. Some code that was found erroneous and causes errors when compiling the transformed code to native code was also taken out while at it. Thanks to @aggelgian for most of the changes in the code.
2016-06-10Merge branch 'hasse/dialyzer/improve_from_form/OTP-13547'Hans Bolinder
* hasse/dialyzer/improve_from_form/OTP-13547: Update primary bootstrap stdlib: Correct types and specs dialyzer: Minor adjustments dialyzer: Suppress unmatched_return for send/2 dialyzer: Improve the translation of forms to types dialyzer: Use a cache when translating forms to types dialyzer: Prepare erl_types:t_from_form() for a cache dialyzer: Optimize erl_types:t_form_form() dialyzer: Correct types syntax_tools: Correct types erts: Correct character repr in doc of the abstract format stdlib: Correct types and specs
2016-06-09Remove support for '...' in Maps typesHans Bolinder
It is possible that '...' is added later (OTP 20.0), but for now we are not sure of all details.
2016-06-09dialyzer: Improve the translation of forms to typesHans Bolinder
Spend less of the limited resources on recursive types.
2016-06-09dialyzer: Use a cache when translating forms to typesHans Bolinder
2016-06-09dialyzer: Prepare erl_types:t_from_form() for a cacheHans Bolinder
No change of functionality.
2016-06-09dialyzer: Optimize erl_types:t_form_form()Hans Bolinder
When the translation from forms to types exceeds some limit, it is faster to try small depths first.
2016-06-09dialyzer: Correct typesHans Bolinder
2016-06-02Revert "Prepare release"Erlang/OTP
This reverts commit e020f75c10410a6943cd055bfa072a2641eab7da.
2016-06-02Prepare releaseErlang/OTP
2016-05-31Code rewrites to avoid exported vars warningsKostis Sagonas
2016-05-31Code rewrites to avoid exported vars compiler warningsKostis Sagonas
2016-05-31Define, export and use a hipe_icode:params() typeKostis Sagonas
2016-05-31Fix name of compiler option and the related warningsKostis Sagonas
2016-05-31Cleanups in hipe/main and hipe/rtlKostis Sagonas
* Rewrite matching statements in ?when_option macro to form that silences dialyzer's unmatched_return warnings * Treat compiler warnings as errors when compiling files in main
2016-05-31Eliminate stupid if constructKostis Sagonas
2016-05-31Use type name, not record notation, in specsKostis Sagonas
2016-05-31Various cleanups and simplificationsKostis Sagonas
2016-05-31Add missing type declarations to a recordKostis Sagonas
2016-05-31Make a type opaqueKostis Sagonas
2016-05-31Cosmetic cleanupsKostis Sagonas
2016-05-31Add compiler option -Werror to MakefilesKostis Sagonas
and correct the name of another, erroneously spelt, option in the process.
2016-05-31Merge branch 'sverker/dialyzer/erlang-halt'Sverker Eriksson
2016-05-30Merge branch 'margnus1/llvm-upgrades/PR-1070'Sverker Eriksson
2016-05-30Reintroduce erlang:halt/0/1 in erl_bif_types.erlSverker Eriksson
Removed in f9cb80861f169743 when changed impl from C to Erlang. But seems they are needed to keep dialyzer tests happy. Also improved bif_SUITE:shadow_comments to include all exported in module erlang, not just the "snifs". ...which detected that apply/2 was missing Shadowed comment as well.
2016-05-27Merge branch 'richcarl/erts/fix-init-stop/PR-911/OTP-13630/OTP-13631'Sverker Eriksson
2016-05-26hipe_llvm: Export hipe literals as LLVM metadataMagnus Lång
LLVM currently hard-codes these. Since it is desirable to be able to change things like PCB layout without requiring a change to LLVM, we export these as LLVM metadata, which can easily be used from LLVM to make it independent of them.
2016-05-26Merge branch 'margnus1/llvm-compatibility/PR-1057/OTP-13626'Sverker Eriksson
2016-05-26Merge branch 'margnus1/hipe/maps-is_key-opts/PR-1069/OTP-13625'Björn-Egil Dahlberg
* margnus1/hipe/maps-is_key-opts/PR-1069/OTP-13625: hipe: Add test suite for verifying optimisations Added elimination of maps:is_key/2 calls to HiPE
2016-05-25hipe: Add halt/2 to functions that always failSverker Eriksson
Seems like halt/2 should be a member of this club.
2016-05-25erts: Implement halt/0 and halt/1 in ErlangSverker Eriksson
just to make things simpler.
2016-05-23hipe: Add test suite for verifying optimisationsErik Norgren
* Added a suite opt_verify_SUITE.erl to HiPE that tests for the results of optimisations, with a single testcase that checks that the icode_call_elim optimisation pass does remove calls to maps:is_key/2 where sound and not otherwise. * Made hipe_testsuite_driver only create explicitly listed suites.