Benedikt Meurer
20efbfefe2
[arm] r12 is destroyed for constants that are not a power of 2.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14260 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-11-02 15:28:26 +00:00
Benedikt Meurer
db057d0beb
[arm] Optimize integer division and modulus by constant.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14259 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-11-02 15:19:20 +00:00
Benedikt Meurer
954f8e5605
Compile multiplication by power of 2 constant to left shift.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14258 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-11-02 12:33:27 +00:00
Xavier Leroy
bdb169a04f
Follow-up to commit r14254: optimization of immediate division and modulus for ARM64. Completely untested.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14257 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-11-01 18:10:18 +00:00
Xavier Leroy
ec4b2fc9a6
Follow-up to commit r14254: optimization of division and modulus by constants for the I386. Untested; CI will find out.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14256 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-11-01 17:29:04 +00:00
Xavier Leroy
e32b161074
Follow-up to commit r14254: update destroyed_at_oper and max_register_pressure
...
for immediate Idiv and Imod.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14255 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-11-01 17:05:21 +00:00
Xavier Leroy
ab9f3e38fb
PR#6042: optimize integer division and modulus when divisor is constant.
...
So far, implemented only for amd64.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14254 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-11-01 16:35:54 +00:00
Xavier Leroy
e499400188
PR#6216: inlining of GADT matches generates invalid assembly
...
(reflecting commit r14251 on version/4.01).
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14252 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-30 14:14:26 +00:00
Jacques Garrigue
9212dd34ac
Add test for PR#6216. Not fixed yet.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14250 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-30 02:57:59 +00:00
Jacques Garrigue
04bc532c2b
Fix PR#6174 (-rectypes case)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14248 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-28 12:08:04 +00:00
Jacques Garrigue
09387da800
Fix PR#6174 (non -rectypes)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14246 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-28 11:49:29 +00:00
Jacques Garrigue
8fb5fdc9f2
merge trunk:14244 to fix bootstrap
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14245 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-24 04:19:08 +00:00
Alain Frisch
87844a6402
Accept change of internal ids.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14243 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-23 15:29:33 +00:00
Alain Frisch
5ef2ee909f
Support for exception values allocated in the static area (e.g. out of bound exception in native code).
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14242 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-23 15:17:05 +00:00
Alain Frisch
fc87ceee89
Cleanup.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14241 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-23 15:04:00 +00:00
Alain Frisch
be3c4d6882
Add two functions to get the exception slot id and name from an exception value.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14240 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-23 14:35:43 +00:00
Alain Frisch
0f6f367ad4
Change the representation of exception slots: instead of being represented as 'string ref', they are now blocks
...
of size 2, with tag = Object_tag, the first field being the pointer to the string, and second one being a unique id, generated
from the same sequence as for object values. Special case for predefined exceptions, represented with a negative id.
The unique id generator is moved from camlinternalOO to the C runtime system.
Also fix some bugs.
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14239 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-23 14:28:31 +00:00
Alain Frisch
fe3afbdce8
Revert bad(?) commit.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14238 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-18 15:15:10 +00:00
Alain Frisch
a96fb5be45
Fix Out_of_memory/Stack_overflow.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14237 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-18 15:14:20 +00:00
Alain Frisch
fc3a6d4be0
Also adapt the native system.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14236 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-18 14:15:27 +00:00
Alain Frisch
d802a51be6
#6203 : change representation of exception values created with a constant constructor: the value is now equal to the exception slot. This avoids some allocation when the constructor is called and an extra indirection on matching against the constructor.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14235 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-18 13:00:58 +00:00
Alain Frisch
804007bfc5
Support for AMD64, Intel syntax (i.e. MVSC 64 port).
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14234 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-15 14:13:26 +00:00
Alain Frisch
4df8c363e8
Fix testsuite.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14233 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-15 13:12:52 +00:00
Alain Frisch
f2597364a2
Support the two variants on i386, intel syntax (i.e. Win32 msvc port).
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14232 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-15 13:09:01 +00:00
Alain Frisch
784b0b3d6e
Support the two variants on i386.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14231 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-15 12:38:11 +00:00
Alain Frisch
0efe8df107
Adapt sparc backend (stacktraces not supported anyway).
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14230 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-15 12:07:23 +00:00
Alain Frisch
0773bfa849
Support raise_notrace under powerpc (not tested). Do not distinguish raise/reraise for now.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14229 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-15 12:06:41 +00:00
Alain Frisch
3f3599f0ee
Support raise_notrace under arm/arm64 (not tested). Do not distinguish raise/reraise for now.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14228 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-15 12:03:47 +00:00
Alain Frisch
ae9a78b10d
Cleanup.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14227 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-14 14:38:18 +00:00
Alain Frisch
164c307ae3
Support for raise variants in ocamlopt. Only amd64 for now.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14226 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-14 14:33:27 +00:00
Alain Frisch
0915cb5b5f
Rename raise_nostack -> raise_notrace. Expose it in Pervasives.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14225 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-14 13:52:14 +00:00
Alain Frisch
c4513e1011
Recognize reraises in handlers.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14224 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-14 13:21:53 +00:00
Alain Frisch
f31325cbaf
#6203 , #5935 : variants of raise. 'reraise' is currently only inserted by the compiler when an handler does not catch the exception. The default 'raise' always start with a fresh backtrace. There is also 'raise_nostack' which does not trigger the stack trace recording. Bytecode only for now.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14223 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-14 12:31:50 +00:00
Alain Frisch
5dabafb940
Branch to experiment with variants of the raise primitive.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14222 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-14 12:12:24 +00:00
Alain Frisch
349f151c0d
Fix testsuite.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14221 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-10 12:29:31 +00:00
Alain Frisch
01aaf23e20
#6205 : add Hint before spellchecking suggestion.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14220 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-10 08:45:40 +00:00
Jacques Garrigue
c628fb2dc9
Do not add module aliases to imports
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14219 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-08 08:18:38 +00:00
Jacques Garrigue
199ace8189
applicative functor application
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14218 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-08 07:21:41 +00:00
Jacques Garrigue
90a081450a
applicative functor application
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14217 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-08 07:14:10 +00:00
Jacques Garrigue
6b45264bb6
debugger
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14216 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-08 03:20:34 +00:00
Jacques Garrigue
f27f4766b4
fix multiple binding of same identifier in apply_coercion, broke core_extended
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14215 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-05 08:49:49 +00:00
Alain Frisch
f1bc74bcc8
#5445 : interpret warning attribute on expressions, and as floating signature/structure items.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14214 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-04 08:18:50 +00:00
Alain Frisch
1b73112593
Allow floating attribute in the toplevel. Also allow the empty structure (;;) as a toplevel phrase.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14213 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-04 07:54:31 +00:00
Jacques Garrigue
7a904bb8db
make path normalization safer; now Core not only compiles but works
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14212 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-04 02:06:40 +00:00
Jacques Garrigue
06d511c857
more exception paths requiring normalization
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14211 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-03 12:51:30 +00:00
Jacques Garrigue
a9ea0064c4
Hurrah: Core compiles (with some warnings)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14210 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-02 16:26:30 +00:00
Alain Frisch
62f365c225
#6195 : use ocamlcommon.cma to link ocamldoc, instead of explicit list of compiler modules.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14209 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-02 14:23:10 +00:00
Jacques Garrigue
c74f7c60e2
fix path comparison. still a problem with FCMod in Core.Binable
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14208 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-02 13:23:48 +00:00
Jacques Garrigue
251289a3a1
fix exn_rebind: camlp4 compiles again
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14207 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-02 08:34:01 +00:00
Alain Frisch
c955798936
Keep attributes with module type declarations. Warning on reference to deprecated module type.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14206 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-01 15:14:04 +00:00