Feature #13

Adapt Makefiles to Debugging/Profiling and split bytecode/native

Added by Alexander Heußner almost 7 years ago. Updated almost 6 years ago.

Status:Closed Start date:05/28/2010
Priority:Normal Due date:
Assignee:Grégoire Sutre % Done:

100%

Category:-
Target version:1.0

Description

Currently, the makefiles automatically generate a bytecode and a native version of our code at the same time. The only difference wrt. to compiler flags is that the bytecode version includes «asserts» and tracebacks whereas the machinecode ignores same:

OCAML_B_FLAGS  ?= -annot -g
OCAML_N_LDFLAGS ?= -annot -noassert -unsafe -inline 100 

This includes certain problems wrt to debugging (with the native binary) and profiling (problems with compilations when using ocamlcp as compiler - no extra bug report submitted). Thus I propose to
  • totally split bytecode and machinecode generation
  • allow different modes for each, e.g., adding -g, -p, and -noassert flags on demand
  • an explicit ocamlcp compilation for bytecode profiling

History

Updated by Alexander Heußner almost 7 years ago

  • Assignee set to Grégoire Sutre

Updated by Alexander Heußner almost 7 years ago

I totally forgot the -annot flag in debugging (=development) mode for generating type annotations (accessible for you favorite editor)

Updated by Alexander Heußner almost 7 years ago

one could take inspiration from Ocaml-Make see details in http://hg.ocaml.info/release/ocaml-make/raw-file/release-6.29.3/README.txt (viz especially profiling and annotations)

Updated by Alexander Heußner almost 7 years ago

split underlying real built problem into bug report #17 (problems with packageing when building purely bytecode version)

Updated by Grégoire Sutre over 6 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

Fixed by switch to ocamlbuild. However, we still can't do byte-code profiling as ocamlbuild does not permit it. But native-code profiling should be sufficient for now.

Updated by Grégoire Sutre almost 6 years ago

  • Target version set to 1.0

Also available in: Atom PDF