[test-suite] r177322 - Disable Shootout-C++ except on non-Darwin ARM
Renato Golin
renato.golin at linaro.org
Mon Mar 18 14:27:36 PDT 2013
Author: rengolin
Date: Mon Mar 18 16:27:35 2013
New Revision: 177322
URL: http://llvm.org/viewvc/llvm-project?rev=177322&view=rev
Log:
Disable Shootout-C++ except on non-Darwin ARM
Moving except test to EH dir to disable it on
non-Darwin ARM until EHABI support gets better
Added:
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/Makefile
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/except.cpp
- copied unchanged from r177317, test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.cpp
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/except.reference_output
- copied unchanged from r177317, test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/except.reference_output.small
- copied unchanged from r177317, test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output.small
Removed:
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.cpp
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output.small
Modified:
test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/Makefile
Added: test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/Makefile
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout-C%2B%2B/EH/Makefile?rev=177322&view=auto
==============================================================================
--- test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/Makefile (added)
+++ test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/EH/Makefile Mon Mar 18 16:27:35 2013
@@ -0,0 +1,7 @@
+LEVEL = ../../../..
+REQUIRES_EH_SUPPORT = 1
+
+include $(LEVEL)/Makefile.config
+
+LDFLAGS += -lstdc++
+include $(LEVEL)/SingleSource/Makefile.singlesrc
Modified: test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/Makefile
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout-C%2B%2B/Makefile?rev=177322&r1=177321&r2=177322&view=diff
==============================================================================
--- test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/Makefile (original)
+++ test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/Makefile Mon Mar 18 16:27:35 2013
@@ -1,8 +1,19 @@
LEVEL = ../../..
CXXFLAGS += -Wno-deprecated
CPPFLAGS += -Wno-deprecated
-REQUIRES_EH_SUPPORT:=1
FP_TOLERANCE := 0.00000001
-LDFLAGS += -lstdc++
+# Exception Handling support in ARM still flaky
+# Re-enable this when support gets better
+ifeq ($(ARCH), ARM)
+ # Darwin uses SjLj, others are either nothing or EHABI
+ # See ARMMCAsmInfo.cpp
+ ifeq ($(TARGET_OS), Darwin)
+ DIRS=EH
+ endif
+else
+ DIRS=EH
+endif
+
+LDFLAGS += -lstdc++
include $(LEVEL)/SingleSource/Makefile.singlesrc
Removed: test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.cpp
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout-C%2B%2B/except.cpp?rev=177321&view=auto
==============================================================================
--- test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.cpp (original)
+++ test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.cpp (removed)
@@ -1,74 +0,0 @@
-// -*- mode: c++ -*-
-// $Id$
-// http://www.bagley.org/~doug/shootout/
-// from Bill Lear
-
-#include <iostream>
-#include <cstdlib>
-#include <cstdio>
-
-using namespace std;
-
-size_t HI = 0;
-size_t LO = 0;
-
-class Hi_exception {
-public:
- explicit Hi_exception(size_t _n) : n(_n) {}
- const char* what() { sprintf(N, "%d", n); return N; }
-private:
- size_t n; char N[8];
-};
-
-class Lo_exception {
-public:
- explicit Lo_exception(size_t _n) : n(_n) {}
- const char* what() { sprintf(N, "%d", n); return N; }
-private:
- size_t n; char N[8];
-};
-
-void blowup(size_t num) {
- if (num % 2) {
- throw Lo_exception(num);
- }
- throw Hi_exception(num);
-}
-
-void lo_function(size_t num) {
- try {
- blowup(num);
- } catch(const Lo_exception& ex) {
- ++LO;
- }
-}
-
-void hi_function(size_t num) {
- try {
- lo_function(num);
- } catch(const Hi_exception& ex) {
- ++HI;
- }
-}
-
-void some_function(size_t num) {
- try {
- hi_function(num);
- } catch (...) {
- cerr << "We shouldn't get here\n"; exit(1);
- }
-}
-
-int
-main(int argc, char* argv[]) {
-#ifdef SMALL_PROBLEM_SIZE
-#define LENGTH 10000
-#else
-#define LENGTH 100000
-#endif
- size_t NUM = (argc == 2 ? (atoi(argv[1]) < 1 ? 1 : atoi(argv[1])): LENGTH);
- while (NUM--) {
- some_function(NUM);
- }
- cout << "Exceptions: HI=" << HI << " / " << "LO=" << LO << endl;
-}
Removed: test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout-C%2B%2B/except.reference_output?rev=177321&view=auto
==============================================================================
--- test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output (original)
+++ test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output (removed)
@@ -1,2 +0,0 @@
-Exceptions: HI=50000 / LO=50000
-exit 0
Removed: test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output.small
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout-C%2B%2B/except.reference_output.small?rev=177321&view=auto
==============================================================================
--- test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output.small (original)
+++ test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/except.reference_output.small (removed)
@@ -1,2 +0,0 @@
-Exceptions: HI=5000 / LO=5000
-exit 0
More information about the llvm-commits
mailing list