[clang] [clang] Use a Worklist for some CodeGenFunctions (PR #115395)

2025-01-02 Thread Stephen Verderame via cfe-commits
@@ -0,0 +1,37 @@ +// RUN: split-file %s %t +// RUN: python %t/gen.py %t/switch-overflow.c %t/tmp.c && %clang_cc1 -emit-llvm %t/tmp.c -o - | FileCheck %t/tmp.c + +//--- gen.py stephenverderame wrote: Sounds good, I can do that. https://github.com/llvm/llvm-proje

[clang] [clang] Use a Worklist for some CodeGenFunctions (PR #115395)

2025-01-01 Thread John McCall via cfe-commits
@@ -0,0 +1,37 @@ +// RUN: split-file %s %t +// RUN: python %t/gen.py %t/switch-overflow.c %t/tmp.c && %clang_cc1 -emit-llvm %t/tmp.c -o - | FileCheck %t/tmp.c + +//--- gen.py rjmccall wrote: If you don't mind working on the representation issue, I think that wou

[clang] [clang] Use a Worklist for some CodeGenFunctions (PR #115395)

2024-12-02 Thread Stephen Verderame via cfe-commits
@@ -0,0 +1,37 @@ +// RUN: split-file %s %t +// RUN: python %t/gen.py %t/switch-overflow.c %t/tmp.c && %clang_cc1 -emit-llvm %t/tmp.c -o - | FileCheck %t/tmp.c + +//--- gen.py stephenverderame wrote: On my local machine, `32,000` seems to work alright and it seem

[clang] [clang] Use a Worklist for some CodeGenFunctions (PR #115395)

2024-12-02 Thread Stephen Verderame via cfe-commits
https://github.com/stephenverderame updated https://github.com/llvm/llvm-project/pull/115395 >From 71702aca23fcc8e2d104d483a40ae16a4a30e48d Mon Sep 17 00:00:00 2001 From: Stephen Verderame Date: Mon, 21 Oct 2024 10:01:43 -0700 Subject: [PATCH] [clang] Use worklist for some CodeGenFunctions Thi

[clang] [clang] Use a Worklist for some CodeGenFunctions (PR #115395)

2024-11-20 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic commented: In general, it's hard to avoid recursion: an AST is fundamentally a tree, and the most natural way to walk a tree is recursive, which is why we have issues in the first place. This usually isn't an issue because people don't write deeply nested code

[clang] [clang] Use a Worklist for some CodeGenFunctions (PR #115395)

2024-11-20 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic edited https://github.com/llvm/llvm-project/pull/115395 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Use a Worklist for some CodeGenFunctions (PR #115395)

2024-11-20 Thread Eli Friedman via cfe-commits
@@ -0,0 +1,37 @@ +// RUN: split-file %s %t +// RUN: python %t/gen.py %t/switch-overflow.c %t/tmp.c && %clang_cc1 -emit-llvm %t/tmp.c -o - | FileCheck %t/tmp.c + +//--- gen.py efriedma-quic wrote: I guess 32000 is small enough that a test won't be that expensive,