Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(209)

Unified Diff: test/cctest/test-cpu-ia32.cc

Issue 23401002: Fix the CPU feature detection. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Improve cpuinfo parsing. Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/cctest/test-cpu.cc ('k') | test/cctest/test-cpu-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-cpu-ia32.cc
diff --git a/test/mjsunit/regress/regress-2671-1.js b/test/cctest/test-cpu-ia32.cc
similarity index 87%
copy from test/mjsunit/regress/regress-2671-1.js
copy to test/cctest/test-cpu-ia32.cc
index 042a501e5adb86cd7d868ec721edef8edde27274..245450bf92b595e417a53edff09a5849d74dd135 100644
--- a/test/mjsunit/regress/regress-2671-1.js
+++ b/test/cctest/test-cpu-ia32.cc
@@ -25,21 +25,16 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax
+#include "v8.h"
-var y;
-function f() {
- var a = [];
- a[20] = 0;
- y = 3;
- var i = 7 * (y + -0);
- a[i]++;
- assertTrue(isNaN(a[i]));
-}
+#include "cctest.h"
+#include "cpu.h"
+
+using namespace v8::internal;
-f();
-f();
-f();
-%OptimizeFunctionOnNextCall(f);
-f();
+TEST(RequiredFeaturesX64) {
+ // Test for the features required by every x86 CPU in compat/legacy mode.
+ CPU cpu;
+ CHECK(cpu.has_sahf());
+}
« no previous file with comments | « test/cctest/test-cpu.cc ('k') | test/cctest/test-cpu-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698