Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0004808OCaml~DO NOT USE (was: OCaml general)public2009-05-28 15:212012-04-08 19:35
Assigned To 
PlatformOSOS Version
Product Version3.10.2 
Target VersionFixed in Version 
Summary0004808: better compilation of min and max
DescriptionPervasives functions min and max never get inlined because they are polymorphic.

Using min or max on int values implies 2 function calls (one to min or max and an indirect one to caml_lessequal).

A specialized version of min and max for type int gets inlined in 0000263:0000004 simple assembler instructions.

A nice feature would be that polymorphic functions get inlined using the knowledge of the actual types of the arguments.

If this is too complicated (or not worth the work) perhaps min and max could be special for the compiler (like '<' is)
TagsNo tags attached.
Attached Files

- Relationships
duplicate of 0005541resolved Pervasives.min/max are not inlined 

-  Notes
xleroy (administrator)
2012-04-08 19:35

Suspending this PR for reasons explained in 0005541

- Issue History
Date Modified Username Field Change
2009-05-28 15:21 jerhoud New Issue
2011-05-31 15:10 doligez Status new => acknowledged
2012-04-08 19:34 xleroy Relationship added duplicate of 0005541
2012-04-08 19:35 xleroy Note Added: 0007295
2012-04-08 19:35 xleroy Status acknowledged => resolved
2012-04-08 19:35 xleroy Resolution open => suspended
2017-02-23 16:36 doligez Category OCaml general => -OCaml general
2017-03-03 17:55 doligez Category -OCaml general => -(deprecated) general
2017-03-03 18:01 doligez Category -(deprecated) general => ~deprecated (was: OCaml general)
2017-03-06 17:04 doligez Category ~deprecated (was: OCaml general) => ~DO NOT USE (was: OCaml general)

Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker