[Symphony-tickets] Re: [SYMPHONY Branch-and-Cut Framework] #27: Port VRP to 64 bit

SYMPHONY Branch-and-Cut Framework coin-trac at coin-or.org
Mon Sep 4 14:43:05 EDT 2006


#27: Port VRP to 64 bit
--------------------+-------------------------------------------------------
 Reporter:  ted     |        Owner:  tkr
     Type:  defect  |       Status:  new
 Priority:  normal  |    Milestone:     
Component:  VRP     |      Version:     
 Severity:  normal  |   Resolution:     
 Keywords:          |  
--------------------+-------------------------------------------------------
Changes (by tkr):

  * owner:  ted => tkr

Old description:

> There is a possible error in the source file vrp_master_functions.c on
> line 74:
>
>    pos = ((int)ed0 - (int)g->edges)/sizeof(edge_data) + 1;
>
> Casting a pointer to int works fine on 32-bit platforms, but it might be
> the case that on some 64-bit platforms an int is still 32-bit wide while
> a pointer occupy 64-bits. Thus, I would change
> that line to:
>
>    pos = ((long)ed0 - (long)g->edges)/sizeof(edge_data) + 1;

New description:

 There is a possible error in the source file vrp_master_functions.c on
 line 74:

    pos = ((int)ed0 - (int)g->edges)/sizeof(edge_data) + 1;

 Casting a pointer to int works fine on 32-bit platforms, but it might be
 the case that on some 64-bit platforms an int is still 32-bit wide while a
 pointer occupy 64-bits. Thus, I would change
 that line to:

    pos = ((long)ed0 - (long)g->edges)/sizeof(edge_data) + 1;

-- 
Ticket URL: <https://projects.coin-or.org/SYMPHONY/ticket/27>
SYMPHONY Branch-and-Cut Framework <http://example.com/>
My example project


More information about the Symphony-tickets mailing list