Ticket #36 (closed defect: fixed)

Opened 6 years ago

Last modified 6 years ago

Bad code generation

Reported by: gfurnish Owned by: somebody
Priority: major Milestone: 0.9.8.1
Component: Optimization Keywords:
Cc:

Description

 147:             x = <TypedSymbolicExpression>PyList_GET_ITEM(operands, i)

      Py_INCREF(((PyObject *)((struct __pyx_obj_4sage_9symbolics_10expression_TypedSymbolicExpression *)PyList_GET_ITEM(__pyx_v_operands, __pyx_v_i))));
      Py_DECREF(((PyObject *)__pyx_v_x));
      __pyx_v_x = ((struct __pyx_obj_4sage_9symbolics_10expression_TypedSymbolicExpression *)PyList_GET_ITEM(__pyx_v_operands, __pyx_v_i));

This should use a temporary instead of calling the thing being casted twice.

Change History

Changed 6 years ago by robertwb

  • status changed from new to closed
  • resolution set to fixed

Changed 6 years ago by robertwb

  • milestone set to 0.9.8.1
Note: See TracTickets for help on using tickets.