Displaying 20 results from an estimated 39 matches for "memalign".
Did you mean:
mem_align
2008 Aug 12
3
aligned memory allocation in C
Hi,
I'm currently R porting SF Mersenne Twister algorithm of Matsumoto and
Saito. To get the full power of their code, I want to use their
fonction fill_array32 which need aligned memory. That is to say I need
to use the C function memalign on windows, posix_memalign on linux and
classic malloc on Mac OS. In 'writing R extenstion', they recommand to
use R_alloc function to allocate memory in C.
Does R_alloc return a pointer to aligned memory?
if not how can I do this?
probably no, because R crashes when I succesively R_al...
2008 Aug 12
3
aligned memory allocation in C
Hi,
I'm currently R porting SF Mersenne Twister algorithm of Matsumoto and
Saito. To get the full power of their code, I want to use their
fonction fill_array32 which need aligned memory. That is to say I need
to use the C function memalign on windows, posix_memalign on linux and
classic malloc on Mac OS. In 'writing R extenstion', they recommand to
use R_alloc function to allocate memory in C.
Does R_alloc return a pointer to aligned memory?
if not how can I do this?
probably no, because R crashes when I succesively R_al...
1998 May 11
0
Tried Compiling 1.9.18p6 yet
...irst Samba 1.9.18p6 doesn't compile under SCO Unix 3.2v4.2:
>
> Linking smbd
> undefined first referenced
> symbol in file
> getpagesize slprintf.o
> mprotect slprintf.o
> memalign slprintf.o
> ld fatal: Symbol referencing errors. No output written to smbd
> *** Error code 13
>
> Stop.
> #
Yes, unfortunately SCO 3.2v4.2 doesn't have these functions. I
created dummy implementations so that I could link.
The vslprintf() functi...
1998 May 11
0
1.9.18p6 release.
...s (it was a problem with code using sprintf)
and released it as 1.9.18p6 on Sunday, May 11th.
Please note that there is no published root exploit for this
problem, other than a denial of service (which is still very
serious).
Unfortunately, in the haste to fix the problem he used
a non-POSIX api, memalign(), in code to simulate the
snprintf() call that sprintf was replaced with. This and
some of the fix code has caused compile problems on some
UNIX systems.
In order to fix these compile problems on as wide a
range of systems as possible, I'd appreciate it if
people could send me the man pages f...
2016 Jun 22
2
[PATCH net-next V2] tun: introduce tx skb ring
...est/ptr_ring.c b/tools/virtio/ringtest/ptr_ring.c
index 26dc1d2..deb36af 100644
--- a/tools/virtio/ringtest/ptr_ring.c
+++ b/tools/virtio/ringtest/ptr_ring.c
@@ -17,6 +17,11 @@
typedef pthread_spinlock_t spinlock_t;
typedef int gfp_t;
+static void *kmalloc(unsigned size, gfp_t gfp)
+{
+ return memalign(64, size);
+}
+
static void *kzalloc(unsigned size, gfp_t gfp)
{
void *p = memalign(64, size);
2016 Jun 22
2
[PATCH net-next V2] tun: introduce tx skb ring
...est/ptr_ring.c b/tools/virtio/ringtest/ptr_ring.c
index 26dc1d2..deb36af 100644
--- a/tools/virtio/ringtest/ptr_ring.c
+++ b/tools/virtio/ringtest/ptr_ring.c
@@ -17,6 +17,11 @@
typedef pthread_spinlock_t spinlock_t;
typedef int gfp_t;
+static void *kmalloc(unsigned size, gfp_t gfp)
+{
+ return memalign(64, size);
+}
+
static void *kzalloc(unsigned size, gfp_t gfp)
{
void *p = memalign(64, size);
2016 Oct 03
3
Default alignment for 'malloc'
...don't
> think there is a way to annotate calls malloc to have some specific
> alignment from the backend, that has effect on passes before the
> backend.
Note that this only applies to base types. Vector types certainly can
require larger alignment in practice and that's why posix_memalign
exists.
Joerg
2002 Sep 11
1
Suggest Rsync Performance Improvements
...this is extremly slow, check it out with Solaris
truss. Use sockets with large I/O or shared memory on
the same system.
To see the difference try
timex dd if=xyz of=lll bs=5k
vs
timex dd if=xyz of=lll bs=1024k
3. When allocating memory which will be accessed all
the time use valloc() which is
memalign(sysconf(_SC_PAGESIZE),size)
It aligns memory to the page, so memory copies are
word/page align and therefore faster, ie. 4 bytes are
copied at once instead of a byte at once.
4. If you use GigaBit ethernet to get performance you
need to read/write 64Kbytes to the socket and let the
OS break it up...
2008 Jul 01
17
Memory leak scripts
Hola, I am trying to isolate the memory leak I suspect in a mailman
installation ? I found:
http://blogs.sun.com/sanjeevb/date/200506
It gives an error:
god at irt-smtp-02:~ 9:21am 65 # ./memleak.d 10312
dtrace: failed to compile script ./memleak.d: line 3: probe description
pid10312:libc.so.1:malloc:entry does not match any probes
I am on SunOS 5.10 Generic_127112-07 i86pc i386 i86pc
Are
2007 Sep 05
1
VP6 issues in Swfdec
...when looking at the code.
-- memleak
http://pown.alluc.org/210.swf
http://pown.alluc.org/991.swf
There's a huge memleak reported by valgrind (this is from a run of 210.swf):
==31127== 224,784,144 bytes in 177 blocks are still reachable in loss
record 5,098 of 5,098
==31127== at 0x4021990: memalign (vg_replace_malloc.c:332)
==31127== by 0x510ECE6: av_malloc (mem.c:61)
==31127== by 0x4D71B01: avcodec_default_get_buffer (utils.c:308)
==31127== by 0x4F4F789: vp56_decode_frame (vp56.c:509)
==31127== by 0x4D70B7D: avcodec_decode_video (utils.c:937)
==31127== by 0x406712D: swfdec_vid...
1998 May 12
0
Compilation problem on OSF/1
.../samba/bin/smbpasswd"
-DSMB_PASSWD_FILE="/us
>r/local/samba/private/smbpasswd"
>Using LIBS =
>Compiling slprintf.c
>/usr/lib/cmplrs/cc/cfe: Error: slprintf.c, line 48: Type for rhs of
assignment e
>xpression is incompatible with lhs (3.3.16.1)
> buf = memalign(pagesize, len);
> ----^
>*** Exit 1
>Stop.
Anyone who knows C and samba better than I do have any ideas?
TIA,
Bruce
Bruce Bowler, Research Associate 207.633.9600 (voice)
Bigelow Laboratory for Ocean Sciences 207.633.9641 (fax)
PO Box 475...
2002 Aug 19
1
small error in Ogg Vorbis FAQ
"Ogg Vorbis uses the Ogg bistream format, and the correct
extension is .ogg"
-- http://www.xiph.org/ogg/vorbis/faq.html
I'm guessing it should read 'bitstream'.
<p>--- >8 ----
List archives: http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org'
2016 Jun 13
0
[PATCH v8 2/5] ptr_ring: ring test
..._cacheline_aligned_in_smp __attribute__ ((aligned (SMP_CACHE_BYTES)))
+#define unlikely(x) (__builtin_expect(!!(x), 0))
+#define ALIGN(x, a) (((x) + (a) - 1) / (a) * (a))
+typedef pthread_spinlock_t spinlock_t;
+
+typedef int gfp_t;
+static void *kzalloc(unsigned size, gfp_t gfp)
+{
+ void *p = memalign(64, size);
+ if (!p)
+ return p;
+ memset(p, 0, size);
+
+ return p;
+}
+
+static void kfree(void *p)
+{
+ if (p)
+ free(p);
+}
+
+static void spin_lock_init(spinlock_t *lock)
+{
+ int r = pthread_spin_init(lock, 0);
+ assert(!r);
+}
+
+static void spin_lock(spinlock_t *lock)
+{
+ int ret = pthre...
2016 Jun 13
0
[PATCH v8 2/5] ptr_ring: ring test
..._cacheline_aligned_in_smp __attribute__ ((aligned (SMP_CACHE_BYTES)))
+#define unlikely(x) (__builtin_expect(!!(x), 0))
+#define ALIGN(x, a) (((x) + (a) - 1) / (a) * (a))
+typedef pthread_spinlock_t spinlock_t;
+
+typedef int gfp_t;
+static void *kzalloc(unsigned size, gfp_t gfp)
+{
+ void *p = memalign(64, size);
+ if (!p)
+ return p;
+ memset(p, 0, size);
+
+ return p;
+}
+
+static void kfree(void *p)
+{
+ if (p)
+ free(p);
+}
+
+static void spin_lock_init(spinlock_t *lock)
+{
+ int r = pthread_spin_init(lock, 0);
+ assert(!r);
+}
+
+static void spin_lock(spinlock_t *lock)
+{
+ int ret = pthre...
2016 Dec 04
2
[Release-testers] 3.9.1-rc2 is ready for testing
...p/llvm/utils/release/rc2/llvm.src/projects/compiler-rt/lib/sanitizer_common/tests/sanitizer_linux_test.cc:230:
Failure
Value of: ThreadDescriptorSize()
Actual: 2288
Expected: (uptr)result
Which is: 2304
Scudo :: alignment.cpp
Scudo :: double-free.cpp
Scudo :: malloc.cpp
Scudo :: memalign.cpp
Scudo :: mismatch.cpp
Scudo :: overflow.cpp
Scudo :: preinit.cpp
Scudo :: quarantine.cpp
Scudo :: realloc.cpp
Scudo :: sized-delete.cpp
Scudo :: sizes.cpp
These ^^ fail to find libatomic when linking. This was added to
libstdc++4.8 but is not present in 4.7. "...
1998 May 11
1
Problems Compiling 1.9.18p6 with SCO 3.2v4.2
...ith Samba:
First Samba 1.9.18p6 doesn't compile under SCO Unix 3.2v4.2 using native
compiler:
Linking smbd
undefined first referenced
symbol in file
getpagesize slprintf.o
mprotect slprintf.o
memalign slprintf.o
ld fatal: Symbol referencing errors. No output written to smbd
*** Error code 13
Stop.
#
Also I keep getting errors when linking that it can't find .o files in the
subdirectories, when compiling them it creates for instance ubi_dLinkList.o in
the parent d...
2005 Sep 02
4
ffmpeg2theora bugs ?
...:
D:\tmp\ffmpeg>ffmpeg -i f:\vi1.avi vo1.avi
ffmpeg version 0.4.9-pre1, build 4743, Copyright (c)
2000-2004 Fabrice Bellard
configuration: --enable-mp3lame --enable-vorbis
--enable-faad --enable-faac -
-enable-xvid --enable-mingw32 --enable-a52
--enable-dts --enable-pp --enable-gpl
--enable-memalign-hack
built on Feb 22 2005 04:58:29, gcc: 3.4.2
(mingw-special)
Input #0, avi, from 'f:\vi1.avi':
Duration: 00:08:04.8, start: 0.000000, bitrate:
30345 kb/s
Stream #0.0: Video: dvvideo, 720x576, 25.00 fps
Stream #0.1: Audio: pcm_s16le, 48000 Hz, stereo,
1536 kb/s
Output #0, avi, to &...
2006 Sep 26
8
Matching Malloc and Free
I would like to profile heap usage on a per thread basis in a large application process. To do this I am tracking calls to malloc and free with the attached script. Everything seems to look OK with some simple test programmes, however, when I track the live system, the results suggest that one thread has grown by approximately 1Gb and I would be surprised if this was true because I ran pmap -x on
2016 Jun 30
9
[PATCH net-next V3 0/6] switch to use tx skb array in tun
Hi all:
This series tries to switch to use skb array in tun. This is used to
eliminate the spinlock contention between producer and consumer. The
conversion was straightforward: just introdce a tx skb array and use
it instead of sk_receive_queue.
A minor issue is to keep the tx_queue_len behaviour, since tun used to
use it for the length of sk_receive_queue. This is done through:
- add the
2016 Jun 30
9
[PATCH net-next V3 0/6] switch to use tx skb array in tun
Hi all:
This series tries to switch to use skb array in tun. This is used to
eliminate the spinlock contention between producer and consumer. The
conversion was straightforward: just introdce a tx skb array and use
it instead of sk_receive_queue.
A minor issue is to keep the tx_queue_len behaviour, since tun used to
use it for the length of sk_receive_queue. This is done through:
- add the