dpdk helloworld代码分析
来源:互联网 发布:php 接口文档管理系统 编辑:程序博客网 时间:2024/05/21 11:06
intmain(int argc, char **argv){ int ret; unsigned lcore_id; ret = rte_eal_init(argc, argv); if (ret < 0) rte_panic("Cannot init EAL\n"); /* call lcore_hello() on every slave lcore */ RTE_LCORE_FOREACH_SLAVE(lcore_id) { rte_eal_remote_launch(lcore_hello, NULL, lcore_id); } /* call it on master lcore too */ lcore_hello(NULL); rte_eal_mp_wait_lcore(); return 0;}
static intlcore_hello(__attribute__((unused)) void *arg){ unsigned lcore_id; lcore_id = rte_lcore_id(); printf("hello from core %u\n", lcore_id); return 0;}
代码首先初始化了Environment Abstraction Layer(EAL),EAL主要提供了以下功能
• Intel® DPDK loading and launching• Support for multi-process and multi-thread execution types• Core affinity/assignment procedures• System memory allocation/de-allocation• Atomic/lock operations• Time reference• PCI bus access• Trace and debug functions• CPU feature identification• Interrupt handling• Alarm operations
http://www.cnblogs.com/chanwai1219/p/3632263.html
0 0
- dpdk helloworld代码分析
- dpdk helloworld代码分析
- DPDK-helloworld实例分析
- DPDK代码内存分析
- dpdk 代码分析一
- DPDK /example/helloworld代码详读
- DPDK helloworld
- DPDK helloworld
- dpdk 代码分析 : 内存初始化
- dpdk 代码分析一 : 内存初始化
- DPDK 代码分析一 : 内存初始化
- dpdk-16.04 — eal初始化代码分析
- DPDK(八):l2fwd代码分析
- cocos2dx HelloWorld代码分析
- DPDK Samples 01HelloWorld
- DPDK-实战之helloworld
- dpdk中文-从helloworld看dpdk
- dpdk 之(一)——代码分析 内存初始化
- 安卓简单的POST和GET请求
- 进程间互斥
- 什么是面向对象设计OOD?
- 我的C语言笔记之经典代码(一)
- 利用elasticsearch的morelikethis功能实现基于内容的相关度推荐
- dpdk helloworld代码分析
- 9—patch图的制作方法
- Tomcat配置多个虚拟主机、部署多个项目
- 页面Tab切点击切换
- Mac OS X系统下修改wifi共享的默认网段
- hihoCoder[Offer收割]编程练习赛1题目解析
- nginx+tomcat+redis完成session共享
- serialVersionUID作用
- Android 搜索框:SearchView 的属性和用法详解