search for: unordered_set

Displaying 20 results from an estimated 22 matches for "unordered_set".

2014 Sep 01
0
[PATCH] nv50/ir: use unordered_set instead of list to keep track of var defs
...alue *rep() const { return join; } + inline Instruction *findOwnDefInsn() const; inline Instruction *getUniqueInsn() const; inline Instruction *getInsn() const; // use when uniqueness is certain @@ -583,11 +584,11 @@ public: static inline Value *get(Iterator&); std::tr1::unordered_set<ValueRef *> uses; - std::list<ValueDef *> defs; + std::tr1::unordered_set<ValueDef *> defs; typedef std::tr1::unordered_set<ValueRef *>::iterator UseIterator; typedef std::tr1::unordered_set<ValueRef *>::const_iterator UseCIterator; - typedef std::list&lt...
2014 Jul 08
1
[PATCH] nv50/ir: use unordered_set instead of list to keep our instructions in uses
...nv50_ir.h b/src/gallium/drivers/nouveau/codegen/nv50_ir.h index 8844030..0ff5e5d 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir.h +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir.h @@ -29,6 +29,7 @@ #include <deque> #include <list> #include <vector> +#include <tr1/unordered_set> #include "codegen/nv50_ir_util.h" #include "codegen/nv50_ir_graph.h" @@ -581,10 +582,10 @@ public: static inline Value *get(Iterator&); - std::list<ValueRef *> uses; + std::tr1::unordered_set<ValueRef *> uses; std::list<ValueDef *> d...
2014 Dec 02
0
[PATCH RESEND] nv50/ir: use unordered_set instead of list to keep track of var defs
...*rep() const { return join; } + inline Instruction *getUniqueInsnMerged() const; inline Instruction *getUniqueInsn() const; inline Instruction *getInsn() const; // use when uniqueness is certain @@ -583,11 +584,11 @@ public: static inline Value *get(Iterator&); std::tr1::unordered_set<ValueRef *> uses; - std::list<ValueDef *> defs; + std::tr1::unordered_set<ValueDef *> defs; typedef std::tr1::unordered_set<ValueRef *>::iterator UseIterator; typedef std::tr1::unordered_set<ValueRef *>::const_iterator UseCIterator; - typedef std::list&lt...
2014 Sep 25
0
[PATCH] nv50/ir: avoid deleting pseudo instructions too early
.../nv50_ir_ra.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp index 4b105b4..d47fed2 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp @@ -25,6 +25,7 @@ #include <stack> #include <limits> +#include <tr1/unordered_set> namespace nv50_ir { @@ -1547,6 +1548,11 @@ SpillCodeInserter::run(const std::list<ValuePair>& lst) LValue *lval = it->first->asLValue(); Symbol *mem = it->second ? it->second->asSym() : NULL; + // Keep track of which instructions to delete late...
2014 Aug 30
2
[PATCH 1/2] nvc0/ir: avoid infinite recursion when finding first uses of tex
...ion *texi, - const Instruction *insn, - std::list<TexUse> &uses) +NVC0LegalizePostRA::findFirstUses( + const Instruction *texi, + const Instruction *insn, + std::list<TexUse> &uses, + std::tr1::unordered_set<const Instruction *>& visited) { for (int d = 0; insn->defExists(d); ++d) { Value *v = insn->getDef(d); for (Value::UseIterator u = v->uses.begin(); u != v->uses.end(); ++u) { Instruction *usei = (*u)->getInsn(); + /* XXX HACK ALERT XX...
2016 Oct 14
2
RFC: Reducing the number of set classes in ADT
tl;dr: I think we have too many different set classes. They have incompatible APIs and surprising behavior. I think we can reduce their number substantially. Dear all, The following is a subset of the set classes we have in ADT: * DenseSet * SmallDenseSet (https://reviews.llvm.org/D25628) * SetVector * SmallSetVector * SmallSet * SmallPtrSet * StringSet * FoldingSet *
2017 Mar 15
2
Use of the C++ standard library in XRay compiler-rt
...s> > > 2 #include <memory> > > 4 #include <mutex> > > 1 #include <system_error> > > 1 #include <thread> > > 2 #include <tuple> > > 1 #include <unordered_map> > > 1 #include <unordered_set> > > 3 #include <utility> > > I think the biggest part is containers, and they are mostly in > ./xray_buffer_queue.h and ./xray_fdr_logging.cc. > > Yes, buffer_queue can definitely live without using system_error, > unordered_map, and unordered_set. It might m...
2017 Mar 08
3
Use of the C++ standard library in XRay compiler-rt
...gt; > 2 #include <limits> > 2 #include <memory> > 4 #include <mutex> > 1 #include <system_error> > 1 #include <thread> > 2 #include <tuple> > 1 #include <unordered_map> > 1 #include <unordered_set> > 3 #include <utility> > I think the biggest part is containers, and they are mostly > in ./xray_buffer_queue.h and ./xray_fdr_logging.cc. > > dependencies without buffer queue and fdr logging: > ...compiler-rt/lib/xray % grep '#include <[^>.]*>' -...
2017 Mar 13
5
Use of the C++ standard library in XRay compiler-rt
...s> > > 2 #include <memory> > > 4 #include <mutex> > > 1 #include <system_error> > > 1 #include <thread> > > 2 #include <tuple> > > 1 #include <unordered_map> > > 1 #include <unordered_set> > > 3 #include <utility> > > I think the biggest part is containers, and they are mostly in > ./xray_buffer_queue.h and ./xray_fdr_logging.cc. > > Yes, buffer_queue can definitely live without using system_error, > unordered_map, and unordered_set. It might m...
2017 Aug 19
1
[PATCH] nv50/ra: Only increment DefValue counter if we are going to spill
...f8f989 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp @@ -1750,8 +1750,7 @@ SpillCodeInserter::run(const std::list<ValuePair>& lst) // multiple destinations that all need to be spilled (like OP_SPLIT). unordered_set<Instruction *> to_del; - for (Value::DefIterator d = lval->defs.begin(); d != lval->defs.end(); - ++d) { + for (Value::DefIterator d = lval->defs.begin(); d != lval->defs.end();) { Value *slot = mem ? static_cast<Value *>(mem) : n...
2017 Jul 31
3
[RFC] Profile guided section layout
Hi Rafael, On 07/31/2017 04:20 PM, Rafael Avila de Espindola via llvm-dev wrote: > However, do we need to start with instrumentation? The original paper > uses sampling with good results and current intel cpus can record every > branch in a program. > > I would propose starting with just an lld patch that reads the call > graph from a file. The format would be very similar to
2017 Mar 08
2
Use of the C++ standard library in XRay compiler-rt
So I stumbled across an issue that I think is a bit fundamental: The xray runtime uses the C++ standard library. This seems like a problem because whatever C++ standard library is used to compile the XRay runtime may not be the same as the C++ standard library (if any) that is used to build the target application and link XRay into. Does this make sense? Is this a problem? Talking to Chandler
2017 Nov 11
2
Update control flow graph when splitting a machine basic block?
Thank you for your reply! > Every MachineBasicBlock has a list of successors; you can access it with > the successors() accessor. That's what you should be using for any CFG > analysis. I am aware of these methods of class MachineBasicBlock, which allows one to access a MachineBasicBlock's successors and predecessors in the CFG. But the CFG itself may no longer be valid if a
2017 Jul 31
2
[RFC] Profile guided section layout
...lude "Threads.h" +#include "llvm/ADT/Hashing.h" #include "llvm/ADT/StringMap.h" #include "llvm/ADT/StringSwitch.h" #include "llvm/Support/FileOutputBuffer.h" #include "llvm/Support/raw_ostream.h" #include <climits> +#include <unordered_set> using namespace llvm; using namespace llvm::ELF; @@ -896,6 +898,157 @@ template <class ELFT> static void sortBySymbolsOrder() { Sec->sort([&](InputSectionBase *S) { return SectionOrder.lookup(S); }); } +// Sort sections by the profile data provided in the .note.llvm.c...
2017 Jun 15
7
[RFC] Profile guided section layout
...lude "Threads.h" +#include "llvm/ADT/Hashing.h" #include "llvm/ADT/StringMap.h" #include "llvm/ADT/StringSwitch.h" #include "llvm/Support/FileOutputBuffer.h" #include "llvm/Support/raw_ostream.h" #include <climits> +#include <unordered_set> using namespace llvm; using namespace llvm::ELF; @@ -922,6 +924,157 @@ static void sortBySymbolsOrder(ArrayRef<OutputSection *> OutputSections) { Sec->sort([&](InputSectionBase *S) { return SectionOrder.lookup(S); }); } +// Sort sections by the profile data provided i...
2018 Aug 09
3
Writing static analyzers to detect non-deterministic behavior?
Thanks for your response David. 1) I'm not sure it's do-able. I don't know of any nice way to track whether an ordered walk of an unordered container leaks out into the final output of the program. Only iterating over an unordered container is probably not a sufficient hint (it'd have a high false positive rate to warn on every instance of that) - and I don't have any
2014 Mar 30
2
CXX_STD and configure.ac in packages
In C++ code for use in a R-3.1.0 package, my specific problem is that I would like to use <unordered_map> if it is available, or <tr1/unordered_map> if not, or <map> if all else fails. I (think I) can accomplish this with configure.ac as AC_INIT("DESCRIPTION") CXX=`"${R_HOME}/bin/R" CMD config CXX` CXXFLAGS=`"${R_HOME}/bin/R" CMD config
2017 Aug 16
4
High Performance containers
Hi, Let me present myself : I work on High Performance Computing, mainly on number crunching where the languages used are mainly Fortran and C++. This field is moving more and more from pure number crunching where Fortran shines to a mix of numbers, texts and other data that you cannot easily deal with Fortran. Unfortunately, the C++ standard library suffers from its age and the fact that it has
2017 Aug 01
2
[RFC] Profile guided section layout
...lude "Threads.h" +#include "llvm/ADT/Hashing.h" #include "llvm/ADT/StringMap.h" #include "llvm/ADT/StringSwitch.h" #include "llvm/Support/FileOutputBuffer.h" #include "llvm/Support/raw_ostream.h" #include <climits> +#include <unordered_set> using namespace llvm; using namespace llvm::ELF; @@ -896,6 +898,153 @@ template <class ELFT> static void sortBySymbolsOrder() { Sec->sort([&](InputSectionBase *S) { return SectionOrder.lookup(S); }); } +// Sort sections by the profile data provided in the .note.llvm.c...
2014 Oct 07
2
[LLVMdev] Can libc++ build for arm cross compiler?
...ut-arm/include/c++/v1/./ctime > -- Installing: > /home/cschen/test/libcxx-scripts/out-arm/include/c++/v1/./system_error > -- Installing: > /home/cschen/test/libcxx-scripts/out-arm/include/c++/v1/./cstdarg > -- Installing: > /home/cschen/test/libcxx-scripts/out-arm/include/c++/v1/./unordered_set > -- Installing: > /home/cschen/test/libcxx-scripts/out-arm/include/c++/v1/./ostream > -- Installing: > /home/cschen/test/libcxx-scripts/out-arm/include/c++/v1/./tuple > -- Installing: > /home/cschen/test/libcxx-scripts/out-arm/include/c++/v1/./__config > -- Installing: > /h...