search for: pstr

Displaying 19 results from an estimated 19 matches for "pstr".

Did you mean: pst
2012 Mar 01
3
Converting a string vector with names to a numeric vector with names
Not paying close attention to detail, I entered the equivalent of pstr<-c("b1=200", "b2=50", "b3=0.3") when what I wanted was pnum<-c(b1=200, b2=50, b3=0.3) There was a list thread in 2010 that shows how to deal with un-named vectors, but the same lapply solution doesn't seem to work here i.e., pnum<-lapply(pstr, as.numer...
2023 Sep 03
1
[PATCH nbdkit] server: Move size parsing code (nbdkit_parse_size) to common/include
This is the first part of a pair of patch series which aim to let us use nbdkit_parse_size (or rather, an equivalent common function) in nbdcopy, so we can write: nbdcopy --request-size=32M ... We can't do that now which was annoying me earlier in the week. This commit creates a new function called human_size_parse which is basically nbdkit_parse_size, and turns nbdkit_parse_size into a
2023 Sep 03
5
[PATCH libnbd 0/5] copy: Allow human sizes for --queue-size, etc
See companion patch: Subject: [PATCH nbdkit] server: Move size parsing code (nbdkit_parse_size) to common/include This is the second part of the patch. It adds the new human_size_parse function to libnbd and then uses it for parsing --queue-size, --request-size and --sparse. The main complication here is that there was already a common/utils/human-size.h header which ends up (eventually)
2005 Jan 31
1
[LLVMdev] Question about Global Variable
...t memory address the initial vaule, not the pointer of constant? I tried to use the following way, std::vector <Value *> idxVec; Value *Zero1 = ConstantInt::get(Type::IntTy , 0); Value *Zero2 = ConstantInt::get(Type::IntTy , 0); idxVec.push_back(Zero1); idxVec.push_back(Zero2); Constant *pStr = ConstantExpr::getGetElementPtr(Cstr, idxVec); // trying to get pointer of initial value GetElementPtrInst *GEP = new GetElementPtrInst( PointerAry , idxVec, "GetAryElement" , BB); // insert getelementptr and get the pionter of AddrOfGstr[0] StoreInst *storeAddr = new StoreInst(pStr...
2015 Sep 01
2
functional bug in code /clients/nutclient.cpp
...et all working properly, except for the nutclient lib in C. Both functions stringset_to_strarr and stringvector_to_strarr have a similar bug in play. Although trivial in code, the coded function does not operate as intended. The pointer increment is missing (see added line marked yellow below [pstr++;]), which results in the same element being updated over and over again, and then only leaving the last element of the list in the array. Kind regards, Paul Vermeer. (also I could not find out how to 'install' the include files properly using the autogen.sh / .configure and mak...
2009 Jul 15
1
Error in simulation R-code
...M,1,1000) Error in nb2listw(dist60, style = "B") : Empty neighbour sets found And, here are my partial data and addition information just in case. > df2007.5k.s2[1:5,] Longitude Latitude Ring stage2 SBA corn sbn w.wit oats afl dbn vg.frt fidle grs.pstr wdlnd nlcd.ow nlcd.dec 821 419.9678 496.3359 5000 2 0.2041200 6.873500 6.515908 5.861865 5.139832 6.260552 5.087444 0.000000 4.818602 6.897949 4.927745 7.073408 7.348551 822 440.9583 533.2685 5000 2 1.1832698 6.829823 6.402711 4.098471 5.660730 6.394553 4.700505 0.000000 4.399483 6....
2009 Apr 01
2
[LLVMdev] adjust address calculus for an architecture that does not address bytes
...I think what you describe is what I meant by 'only catch the targeted addresses of loads/stores', i.e. the address the instruction is reading from/writing to. However, if I have e.g. a chunk of code which stores the address of the second element of struct str somewhere into another struct pstr: %0 = getelementptr %struct.str* %s, i32 0, i32 1 ; <i16*> [#uses=1] %1 = getelementptr %struct.pstr* %ps, i32 0, i32 5 ; <i16**> [#uses=1] store i16* %0, i16** %1, align 4 Your suggestion allows to store the i32* at the right place...
2007 Nov 07
4
[LLVMdev] LLVM 2.1 with VC++
I've come across a couple errors when building LLVM 2.1 in VC++ 2005. 1) CodeGen/RegisterCoalescer.cpp is not included in the project 2) System/Win32/DynamicLibrary.inc - ELM_Callback is declared with a PSTR ModuleName argument. This causes a compile error - the callback typedef specifies PCSTR. Also, I'd like to suggest adding the following to config.h, to eliminate the spurious deprecation warnings: #define _CRT_SECURE_NO_WARNINGS #define _SCL_SECURE_NO_WARNINGS #define _CRT_NONSTDC_NO_WARNING...
2023 Sep 05
1
[PATCH nbdkit] server: Move size parsing code (nbdkit_parse_size) to common/include
On Tue, Sep 05, 2023 at 11:09:02AM +0100, Richard W.M. Jones wrote: > > > +static inline int64_t > > > +human_size_parse (const char *str, > > > + const char **error, const char **pstr) > > > +{ > > > + int64_t size; > > > + char *end; > > > + uint64_t scale = 1; > > > + > > > + /* XXX Should we also parse things like '1.5M'? */ > > > + /* XXX Should we allow hex? If so, hex cannot use scaling suffixes, &...
2009 Mar 31
0
[LLVMdev] adjust address calculus for an architecture that does not address bytes
Christian Sayer wrote: > Hi, > my target architecture has a kind of "16bit addressing mode", i.e. one address does not address 8 bit but a 16bit chunk. Consequently, every constant used to calculate effective addresses must be divided by two. > So far this is not such a problem for stack objects since FrameIndexes, function arguments etc. have a lot of custom lowering code where
2009 Mar 31
2
[LLVMdev] adjust address calculus for an architecture that does not address bytes
Hi, my target architecture has a kind of "16bit addressing mode", i.e. one address does not address 8 bit but a 16bit chunk. Consequently, every constant used to calculate effective addresses must be divided by two. So far this is not such a problem for stack objects since FrameIndexes, function arguments etc. have a lot of custom lowering code where this can be done. But when it comes
2009 Apr 08
0
[LLVMdev] DynamicLibrary.inc compile error /w vc++2005 and windows sdk 6.1
Hello there, I'm having a problem compiling llvm with vc++ 2005 and windows sdk6.1. It seems that the Platform SDK supplied with vc++2005 uses PSTR for the first param of PENUMLOADED_MODULES_CALLBACK64 typedef (dbghelp.h) and the windows sdk 6.1 (also windows sdk 6.0a that ships with vc++2008) uses PCSTR. The _MSC_VER macro guard for ELM_Callback(...) kinda kills the possibility of using VC++2005 with SDK 6.1 and without the macro guard,...
2008 Feb 21
1
[LLVMdev] Is there someone tried LLVM 2.1 on Visual Studio 2005?
...t Line 126 in the file DynamicLibrary.inc. >// EnumerateLoadedModules(GetCurrentProcess(), ELM_Callback, 0); >Maybe MS changed the parameter type in the latest platform SDK. > >A simple workaround. At line 47 in the same file DynamicLibrary.inc, >// static BOOL CALLBACK ELM_Callback(PSTR ModuleName, ... >change PSTR to PCSTR, and everything is OK. > >I don't know if this works for VS2005/XP. > >Xi >_______________________________________________ >LLVM Developers mailing list >LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu >http://lists.cs.uiu...
2009 Aug 11
2
[LLVMdev] Bug in optimization pass related to strcmp and big endian back-ends
Hi all, i'm working on a LLVM back-end right now and i think I found a bug in an optimization pass. When compiling the following code using llvm-gcc (the current 2.5 release) with -O2 int main(int argc, char** argv) { char* pStr = "I" + (argc > 100); printf("%d\n", strcmp(pStr, "I") == 0); } the strcmp function is replaced by a 16 bit load and compared against the integer value of 'I': define i32 @main(i32 %argc, i8** nocapture %argv) nounwind {...
2008 Feb 12
3
[LLVMdev] Is there someone tried LLVM 2.1 on Visual Studio 2005?
Hello all, Is there anyone has tried LLVM 2.1 on Visual Studio 2005? I did but not succeed due to some build errors. I seem to remember I read somewhere on this list it's compiled on VS2005 so I wonder... Have a good night. Thx, Seung
2011 Nov 02
3
[LLVMdev] [PATCH] LLVM 3.0 broken in lib/Support/Windows/DynamicLibrary.inc
...; (!defined(VER_PRODUCTBUILD) || VER_PRODUCTBUILD < 6000) + #define OLD_ELM_CALLBACK_DECL 1 + #endif +#elif defined(__MINGW64__) + // Use new callback. +#elif defined(__MINGW32__) + #define OLD_ELM_CALLBACK_DECL 1 +#endif + +#ifdef OLD_ELM_CALLBACK_DECL + static BOOL CALLBACK ELM_Callback(PSTR ModuleName, + DWORD_PTR ModuleBase, + ULONG ModuleSize, + PVOID UserContext) +#else + static BOOL CALLBACK ELM_Callback(PCSTR ModuleName, + DWORD_PTR Module...
2006 Mar 25
1
Help with File.set_permissions port
I''ve got a (broken) version of File.set_permissions in CVS, and I need some help finishing it off please. Heesob, can you take a look? Thanks, Dan
2005 Feb 02
1
[LLVMdev] RE: Question about Global Variable
...ollowing way, > > > > std::vector <Value *> idxVec; > > Value *Zero1 = ConstantInt::get(Type::IntTy , 0); > > Value *Zero2 = ConstantInt::get(Type::IntTy , 0); > > > > idxVec.push_back(Zero1); > > idxVec.push_back(Zero2); > > > > Constant *pStr = ConstantExpr::getGetElementPtr(Cstr, idxVec); // trying to get pointer of initial value > > Very close. Try using gI instead of Cstr. > > > Is the question clear? How could I fix it? Thanks so much. > > Try the above, and please let me know if it doesn't help! > &...
2006 Apr 26
2
Unable to accept incoming PSTN calls
I am new to Asterisk and the protocol/language complex world of VoIp and PBX. But I have a dedicated machine running A@H 2.8, a single TDM400P with one FXS module card connected to a standard analog phone. The second card is an X100P connected to my analog PSTN phone line. I also have Grandsteam IP phone plugged into the network and a couple of x-lite SIP softphones. I can make outgoing calls on