Branch: Tag:

2019-03-29

2019-03-29 11:50:45 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Compiler: Reuse inherited references that are already inline.

There is no need to create a new ID_INLINE reference if there
already exists one from the inherit.

5136:    * Reference number in q->new_program->inherit[i].prog.    *    * @return -  * Returns an equivalent reference that is INLINE|HIDDEN. +  * Returns an equivalent reference that is INLINE (and HIDDEN if +  * a new reference was created).    *    * Returns -1 if the referenced identifier is -1 or a prototype.    */
5175:       if ((refp->inherit_offset == funp.inherit_offset) &&    (refp->identifier_offset == funp.identifier_offset) && -  ((refp->id_flags | ID_USED) == (funp.id_flags | ID_USED))) { +  ((refp->id_flags & (ID_INLINE|ID_EXTERN|ID_VARIANT)) == +  (funp.id_flags & (ID_INLINE|ID_EXTERN|ID_VARIANT)))) {    return d;    }    }