x86-64

Evaluating SMI (System Management Interrupt) latency on Linux-CentOS/Intel machine

早过忘川 提交于 2019-12-03 03:21:30
I am interested in evaluating the behavior (latency, frequency) of SMI handling on Linux machine running CentOS and used for a (very) soft real time application. What tools are recommended (hwlatdetect for CentOS?), and what is the best course of action to go about this? If no good tools are available for CentOS, am I correct to assume that installing a different OS on the same machine should yield the same results since the underlying hardware/bios are the same? Is there any source for ballpark figures on these parameters. The machines are X86_64 architecture, running CentOS 6.4 (kernel 2.6

SSE: unaligned load and store that crosses page boundary

China☆狼群 提交于 2019-12-03 03:13:52
I read somewhere that before performing unaligned load or store next to page boundary (e.g. using _mm_loadu_si128 / _mm_storeu_si128 intrinsics), code should first check if whole vector (in this case 16 bytes) belongs to the same page, and switch to non-vector instructions if not. I understand that this is needed to prevent coredump if next page does not belong to process. But what if both pages belongs to process (e.g. they are part of one buffer, and I know size of that buffer)? I wrote small test program which performed unaligned load and store that crossed page boundary, and it did not

Problem of loading mod_wsgi module into apache on Windows 64-bit

馋奶兔 提交于 2019-12-03 03:08:10
I'm trying to install mod_wsgi module followed this instruction . I've downloaded mod_wsgi.so from this source . It seems like apache cannot restart services properly and the page cannot be loaded after I added the following line to httpd.conf LoadModule wsgi_module modules/mod_wsgi.so I've checked some issues from some sources as follows: The file name is correct - mod_wsgi.so not mod_wsgi.so.so Permissions on the file was set as same as other modules that loaded properly Python installed for all users Environment: Windows Server® Standard FE 64-bit Apache 2.2.8 on WAMP 2.0 Python 2.7.1

Cross compile windows 64 bit .exe from linux

℡╲_俬逩灬. 提交于 2019-12-03 02:58:04
I know that if I want to compile a 32 bit .exe for windows on Linux I can just install and use the mingw32 package (e.g. apt-get install mingw32) on linux. What if I want to compile a windows .exe that is 64 bit? Is there tools or a method to do this? It looks like my answer lies with the Mingw-w64 project which is available for host OSes Linux, Darwin & Windows 来源: https://stackoverflow.com/questions/2689813/cross-compile-windows-64-bit-exe-from-linux

Intel x86-64 XSAVE/XRSTOR

匿名 (未验证) 提交于 2019-12-03 02:24:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I'm a CS student writing in Intel x86-64 assembly, compiling with nasm , and running on an Core i7 processor with Ubuntu 12.04 as the guest OS. Does anyone have an example of how to use XSAVE and XRSTOR ? I've read the section on XSAVE in Intel Architectures Software Developers manual several times. I tried to implement xsave in C++ and then disassemble the binary to get an understanding of what it's doing. And of course I've scoured the Internet for examples. Any suggestions would be much obliged. 回答1: Finally, an answer to this question.

Bounds check in 64bit hardware

岁酱吖の 提交于 2019-12-03 01:47:20
I was reading a blog on 64-bit Firefox edition on hacks.mozilla.org . The author states: For asm.js code, the increased address space also lets us use hardware memory protection to safely remove bounds checks from asm.js heap accesses. The gains are pretty dramatic: 8%-17% on the asmjs-apps-*-throughput tests as reported on arewefastyet.com . I was trying to understand how 64-bit hardware have automatic bounds check (assuming compiler does with hardware support) for C/C++. I could not find any answers in SO. I found one technical paper on this subject , but I am not able to grasp how this is

Benefits of x87 over SSE

你。 提交于 2019-12-03 01:19:11
I know that x87 has higher internal precision, which is probably the biggest difference that people see between it and SSE operations. But I have to wonder, is there any other benefit to using x87? I have a habit of typing -mfpmath=sse automatically in any project, and I wonder if I'm missing anything else that the x87 FPU offers. Nils Pipenbrinck For hand-written asm, x87 has some instructions that don't exist in the SSE instruction set. Off the top of my head, it's all trigonometric stuff like fsin, fcos, fatan, fatan2 and some exponential/logarithm stuff. With gcc -O3 -ffast-math -mfpmath

Compilers: Understanding assembly code generated from small programs

╄→гoц情女王★ 提交于 2019-12-03 00:41:13
I'm self-studying how compilers works. I'm learning by reading the disassembly of GCC generated code from small 64-bit Linux programs. I wrote this C program: #include <stdio.h> int main() { for(int i=0;i<10;i++){ int k=0; } } After using objdump I get: 00000000004004d6 <main>: 4004d6: 55 push rbp 4004d7: 48 89 e5 mov rbp,rsp 4004da: c7 45 f8 00 00 00 00 mov DWORD PTR [rbp-0x8],0x0 4004e1: eb 0b jmp 4004ee <main+0x18> 4004e3: c7 45 fc 00 00 00 00 mov DWORD PTR [rbp-0x4],0x0 4004ea: 83 45 f8 01 add DWORD PTR [rbp-0x8],0x1 4004ee: 83 7d f8 09 cmp DWORD PTR [rbp-0x8],0x9 4004f2: 7e ef jle 4004e3

oracle 11.2.0.1 for windows server2012R2应用p12429529_112010_MSWIN-x86-64补丁

♀尐吖头ヾ 提交于 2019-12-03 00:41:10
oracle 11.2.0.1 for windows server2012R2应用p12429529_112010_MSWIN-x86-64补丁集,也是oracle数据库安全加固的范畴。因为每次oracle数据库加固过程中 总会有些许意外发生,这里记录一次oracle 11.2.0.1 for windows server2012R2应用p12429529_112010_MSWIN-x86-64补丁集。 本次oracle安全加固使用的参考文档: 一、目的 针对windwos server 2012/2012R2平台上运行的oracle数据库 11.2.0.1应用目前可用最新的CPU补丁集p12429529,修复该版本数据库在日常应用中的风险漏洞, 减少应用系统架构非计划停机时间、屏蔽数据库风险漏洞被利用的可能。 二、安全加固基础信息 操作系统类型 数据库版本 预用补丁版本 备注 windows server 2012R2 oracle 11.2.0.1 p12429529_112010_MSWIN-x86-64  最新CPU windows server 2012 oracle 11.2.0.1 p12429529_112010_MSWIN-x86-64  最新CPU 三、安全加固操作步骤 1、 对预用补丁集数据库的应用进行关停; 2、 对预用补丁集数据库进行基础健康检查; 3、

X86-64和ARM64用户栈的结构

匿名 (未验证) 提交于 2019-12-03 00:40:02
背景 ????主要基于Linux,介绍X86-64和ARM64的用户栈结构。断断续续的学了很多和栈相关的知识,今天打算整理用户栈相关的知识,废话少说,下面进入正题。在最初的最初,用户栈是OS创建的。 进程的创建 ????一个用户进程从无到开始运行,需要经过几个重要的步骤: Linux首先创建一个task_struct用于管理进程的方方面面。 建立进程的虚拟地址空间,也即建立页表,建立虚拟地址到物理地址的映射,到这时一个用户进程所需的基本元素已经具备,到这里frok()的任务基本完成。 接下来就需要可执行文件本身的参与,读取可执行文件头,解析文件头,文件头的前几个字节会指出当前文件是何种类型,如果是#!/bin/sh或 #!/bin/python 则该文件是脚本文件,有负责脚本文件的加载程序,本文只关注可执行文件。建立虚拟地址和可执行文件之间的映射。 初始化进程环境, 其中比较重要的一项便是初始化用户进程栈 跳转到可执行文件的入口,执行可执行文件,一个用户进程就开始运行起来了 用户进程栈的初始化 在进程刚开始运行的时候,需要知道运行的环境和用户传递给进程的参数。一般来说,Linux会在用户进程运行前,将系统的环境变量和用户给的参数保存到用户虚拟地址空间的栈中。 原文:http://blog.51cto.com/iamokay/2138525