Debian Codegraph @

gcc/testsuite/g++.target/i386/pr105638.C

raw
1 /* { dg-do compile { target { ! ia32 } } } */
2 /* { dg-options "-std=gnu++20 -O2 -march=skylake" } */
3 /* { dg-final { scan-assembler-not "call\[\\t \]_?memset\[\r\n\]\[^\r\n\]movq\[\\t \]%\[a-z0-9]*, %\[a-z0-9]*\[\r\n\]\[^\r\n\]vpxor\[\\t \]%xmm0, %xmm0, %xmm0\[\r\n\]\[^\r\n\]vmovdqu\[\\t \]%xmm0, 36\\(%rax\\)" } } */
4 /* { dg-skip-if "requires hosted libstdc++ for vector" { ! hostedlib } } */
5
6
7 #include <stdint.h>
8 #include <vector>
9 #include <tr1/array>
10
11 class FastBoard {
12 public:
13 typedef std::pair<int, int> movescore_t;
14 typedef std::tr1::array<movescore_t, 24> scoredlist_t;
15
16 protected:
17 std::vector<int> m_critical;
18
19 int m_boardsize;
20 };
21
22 class FastState {
23 public:
24 FastBoard board;
25
26 int movenum;
27 protected:
28 FastBoard::scoredlist_t scoredmoves;
29 };
30
31 class KoState : public FastState {
32 private:
33 std::vector<uint64_t> ko_hash_history;
34 std::vector<uint64_t> hash_history;
35 };
36
37 class GameState : public KoState {
38 public:
39 void foo ();
40 private:
41 std::vector<KoState> game_history;
42 };
43
44 void GameState::foo() {
45 game_history.resize(movenum);
46 }