Re: copyinstr()

2013-04-09 Thread Xin Li
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 4/8/13 6:15 PM, Vijay Singh wrote: Hi, I was looking for some help with copyinstr() on an amd64 platform. My from address happens to be in the kernel (stack). I am getting an EFAULT, and I am wondering how to fix that. Since you are doing

Re: building world and kernel without ebuilding (bootstrap?) clang?

2013-04-09 Thread Lev Serebryakov
Hello, deeptech71. You wrote 9 апреля 2013 г., 3:06:42: d 1. Add the following or similar to /etc/make.conf: d CC=/full/path/to/clang d CPP=/full/path/to/clang-cpp d CXX=/full/path/to/clang++ d Note: make sure clang-cpp or similar exists. d 2. Add the following to /etc/src.conf: d WITHOUT_GCC=1

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Alfred Perlstein
On 4/8/13 6:42 PM, Adrian Chadd wrote: Well, it's relatively easy to experience what it's like. No it's not. We all have jobs that demand different things from us. Taking the time to guess at the problem, only to be told you're doing it wrong by someone actually in the position to build

Re: copyinstr()

2013-04-09 Thread Oliver Pinter
On 4/9/13, Vijay Singh vijju.si...@gmail.com wrote: Hi, I was looking for some help with copyinstr() on an amd64 platform. My from address happens to be in the kernel (stack). I am getting an EFAULT, and I am wondering how to fix that. Would using memory from malloc() make a difference? The

Re: building world and kernel without ebuilding (bootstrap?) clang?

2013-04-09 Thread Lev Serebryakov
Hello, deeptech71. You wrote 9 апреля 2013 г., 3:06:42: d There are some issues when building updated sources [1]. There d was a thread about adding support for an external compiler [2], d but that yielded a non-working solution [3]. Ok, World build time was reduced from 1:27 to just 0:27.

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Wojciech Puchar
happy that FreeBSD is among the selected organization. I am a third year student interested to work in the field of embedded system. I applied last year and the title of my project was Kernel Size why only in embedded system. smaller programs are always good :) And yes FreeBSD kernel is huge.

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Alfred Perlstein
On 4/9/13 10:36 AM, Wojciech Puchar wrote: happy that FreeBSD is among the selected organization. I am a third year student interested to work in the field of embedded system. I applied last year and the title of my project was Kernel Size why only in embedded system. smaller programs are

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Wojciech Puchar
And yes FreeBSD kernel is huge. doesn't really matter with 1GB or more RAM but yes - it is huge even relative to linux. Ah, any insight as to why? my custom compiled kernel: -r-xr-xr-x 1 root wheel 8791402 6 kwi 22:08 /boot//kernel/kernel only with features i need. linux is AFAIK like

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Kimmo Paasiala
On Tue, Apr 9, 2013 at 8:53 PM, Wojciech Puchar woj...@wojtek.tensor.gdynia.pl wrote: And yes FreeBSD kernel is huge. doesn't really matter with 1GB or more RAM but yes - it is huge even relative to linux. Ah, any insight as to why? my custom compiled kernel: -r-xr-xr-x 1 root wheel

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Freddie Cash
You have to look at the in-memory sizes, not the on-disk sizes. Linux kernels are very barebones when it comes to what is compiled directly into the kernel image on disk. Everything else is loaded from modules at boot time. Especially if using distro-provided kernels. They even use ram disks /

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Lev Serebryakov
Hello, Kimmo. You wrote 9 апреля 2013 г., 21:59:37: KP Your comparison is far from accurate, include the memory taken by KP loaded kernel modules on both systems and then you might get some KP proper numbers. Linux is known to _work_ on SOHO MIPS boxes, with 4MiB of flash and 16MiB of RAM. You

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Edward Tomasz Napierała
In order to optimize - in this case for size - we need a way to measure what should we focus on, and it looks like we don't have it yet. Would it be possible to write a tool - e.g. by instrumenting LLVM - that would make it possible to calculate, for every function in the call graph, the amount

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Adrian Chadd
On 9 April 2013 11:47, Edward Tomasz Napierała tr...@freebsd.org wrote: In order to optimize - in this case for size - we need a way to measure what should we focus on, and it looks like we don't have it yet. We have a good starting point. We can look at the code/data/bss from each .o file

Re: building world and kernel without ebuilding (bootstrap?) clang?

2013-04-09 Thread deeptech71
Lev Serebryakov wrote: Is system version (system is snapshot from Mar 30) is external and modern? No. The base version of Clang has been patched to work well with the base system, at least regarding the discussed issue of standard header files. Lev Serebryakov wrote: It is very sad,

Re: GSOC 2013 project Kernel Size Reduction for Embedded System

2013-04-09 Thread Joshua Isom
On 4/9/2013 1:47 PM, Edward Tomasz Napierała wrote: In order to optimize - in this case for size - we need a way to measure what should we focus on, and it looks like we don't have it yet. Would it be possible to write a tool - e.g. by instrumenting LLVM - that would make it possible to