https://codereview.chromium.org/1153373003/diff/140001/src/factory.h
File src/factory.h (right):
https://codereview.chromium.org/1153373003/diff/140001/src/factory.h#newcode355
src/factory.h:355: Handle<Float32x4> NewFloat32x4(double w, double x,
double y, double z,
Should we use float here to force the rounding into the caller?
https://codereview.chromium.org/1153373003/diff/140001/src/heap/heap.h
File src/heap/heap.h (right):
https://codereview.chromium.org/1153373003/diff/140001/src/heap/heap.h#newcode1610
src/heap/heap.h:1610: AllocateFloat32x4(double w, double x, double y,
double z,
Float
https://codereview.chromium.org/1153373003/diff/140001/src/objects-inl.h
File src/objects-inl.h (right):
https://codereview.chromium.org/1153373003/diff/140001/src/objects-inl.h#newcode1587
src/objects-inl.h:1587: DCHECK(lane < 4 && lane >= 0);
Looks like we are only supporting little endian for now. I suppose
that's OK.
https://codereview.chromium.org/1153373003/diff/140001/src/objects.cc
File src/objects.cc (right):
https://codereview.chromium.org/1153373003/diff/140001/src/objects.cc#newcode100
src/objects.cc:100: if (IsFloat32x4()) return
Float32x4::cast(this)->Float32x4BooleanValue();
Maybe it's better just to return true for now here, since the rest of
the system will treat all objects as true. There'll be a lot of work to
make the value-objectness work correctly in V8, so let's just be
consistent for now.
https://codereview.chromium.org/1153373003/diff/140001/src/objects.h
File src/objects.h (right):
https://codereview.chromium.org/1153373003/diff/140001/src/objects.h#newcode1621
src/objects.h:1621: inline double get_lane(int lane) const;
I think we should float here too.
https://codereview.chromium.org/1153373003/diff/140001/src/objects.h#newcode1634
src/objects.h:1634: #if defined(V8_TARGET_LITTLE_ENDIAN)
Can we leave these out of the header to force users to go through the
get_lane() and set_lane() methods?
https://codereview.chromium.org/1153373003/diff/140001/test/cctest/test-heap.cc
File test/cctest/test-heap.cc (right):
https://codereview.chromium.org/1153373003/diff/140001/test/cctest/test-heap.cc#newcode187
test/cctest/test-heap.cc:187: value = factory->NewFloat32x4(1, 2, 3, 4);
Can we try some more floating point values, and also -0.0 and NaN
values?
You can write your own method with lots of example values and exhaustive
reading and writing of the individual lanes.
https://codereview.chromium.org/1153373003/
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.