u3: shortcircuit direct atoms in u3i_chub()

This commit is contained in:
Joe Bryan 2021-04-22 15:54:19 -07:00
parent af1325a387
commit 9c550a6795

View File

@ -313,6 +313,10 @@ u3i_word(c3_w dat_w)
u3_atom
u3i_chub(c3_d dat_d)
{
if ( c3y == u3a_is_cat(dat_d) ) {
return (u3_atom)dat_d;
}
else {
c3_w dat_w[2] = {
dat_d & 0xffffffffULL,
dat_d >> 32
@ -320,6 +324,7 @@ u3i_chub(c3_d dat_d)
return u3i_words(2, dat_w);
}
}
/* u3i_bytes(): Copy [a] bytes from [b] to an LSB first atom.
*/