Skip to content
Advertisement

Tag: x86-64

How to use 1GB hugepages in DPDK?

DPDK has two hugepage sizes:2MB hugepages and 1GB hugepages. I run the command below to use the 1GB hugepages: However, when I run the command cat /proc/meminfo: It still seems to use the 2MB hugepages. What should I do to use the 1GB hugepages? Answer The Hugepagesize field of /proc/meminfo is the default huge page size used by applications allocating

Why does this nostdlib C++ code segfault when I call a function with a thread local variable? But not with a global var or when I access members?

Assembly included. This weekend I tried to get my own small library running without any C libs and the thread local stuff is giving me problems. Below you can see I created a struct called Try1 (because it’s my first attempt!) If I set the thread local variable and use it, the code seems to execute fine. If I call

Understanding ELF64 text/data segment layout/padding

I’m trying to brush up on UNIX viruses and one text I’m reading mentions that parasitic code can be inserted in the padding between the text and the data segment, supposedly up to 2MB in size on x86-64 systems. But when I compile a simple hello world program with gcc -no-pie… …and inspect its segment headers with readelf -W -l

get a char passed as parameter

I would like to write a function in NASM System V ABI x86-64 (Intel Syntax) that I could use in a C program. Here is the prototype of the function: I therefore retrieve the parameters in order (const char *s = rdi, int c = rsi) First, I get the character stored in the register rsi and put it in

Clang 11 and GCC 8 O2 Breaks Inline Assembly

I have a short snippet of code, with some inline assembly that prints argv[0] properly in O0, but does not print anything in O2 (when using Clang. GCC, on the other hand, prints the string stored in envp[0] when printing argv[0]). This problem is also restricted to only argv (the other two function parameters can be used as expected with

How to run Rebol script on Linux 64-bit

I can not run this sample Rebol script on Debian 10 Linux 64-bit OS. The script is from the official Rebol tutorial. I’m trying to run it using this command from console: but it fails with error message I use the latest available build for Linux x86-64 from the official Rebol site. How to run the script? Does Rebol support

Advertisement