@staticmethod<EOL><INDENT>def max_or(a, b, c, d, w):<DEDENT>
m = (<NUM_LIT:1> << (w - <NUM_LIT:1>))<EOL>while m != <NUM_LIT:0>:<EOL><INDENT>if (b & d & m) != <NUM_LIT:0>:<EOL><INDENT>temp = (b - m) | (m - <NUM_LIT:1>)<EOL>if temp >= a:<EOL><INDENT>b = temp<EOL>break<EOL><DEDENT>temp = (d - m) | (m - <NUM_LIT:1>)<EOL>if temp >= c:<EOL><INDENT>d = temp<EOL>break<EOL><DEDENT><DEDENT>m >>= <NUM_LIT:1><EOL><DEDENT>return b | d<EOL>
Upper bound of result of ORing 2-intervals.

:param a: Lower bound of first interval
:param b: Upper bound of first interval
:param c: Lower bound of second interval
:param d: Upper bound of second interval
:param w: bit width
:return: Upper bound of ORing 2-intervals