From owner-freebsd-toolchain@FreeBSD.ORG Fri Jun 10 15:38:38 2011 Return-Path: Delivered-To: toolchain@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E8ADF1065672; Fri, 10 Jun 2011 15:38:38 +0000 (UTC) (envelope-from marcel@xcllnt.net) Received: from mail.xcllnt.net (mail.xcllnt.net [70.36.220.4]) by mx1.freebsd.org (Postfix) with ESMTP id 9CAE68FC0A; Fri, 10 Jun 2011 15:38:38 +0000 (UTC) Received: from dhcp-192-168-2-22.wifi.xcllnt.net (atm.xcllnt.net [70.36.220.6]) (authenticated bits=0) by mail.xcllnt.net (8.14.4/8.14.4) with ESMTP id p5AFcWHC068663 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Fri, 10 Jun 2011 08:38:38 -0700 (PDT) (envelope-from marcel@xcllnt.net) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: Marcel Moolenaar In-Reply-To: <20110610072512.GA35144@freebsd.org> Date: Fri, 10 Jun 2011 08:38:38 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <5A6AC098-FB0D-474A-B92D-190121CA400F@xcllnt.net> References: <20110610072512.GA35144@freebsd.org> To: Roman Divacky X-Mailer: Apple Mail (2.1084) Cc: toolchain@freebsd.org Subject: Re: llvm-ia64 is off the ground... X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jun 2011 15:38:39 -0000 On Jun 10, 2011, at 12:25 AM, Roman Divacky wrote: > On Thu, Jun 09, 2011 at 07:20:04PM -0700, Marcel Moolenaar wrote: >> [CC toolchain@ -- more eyes is probably better] >>=20 >> Hi Roman, >>=20 >> I created the projects branch and committed a skeletal target >> for ia64 that's based on MSP430. I also discovered that CLang >> needs some target info, so I added that too. >>=20 >> The branch is: >> projects/llvm-ia64 >=20 > wow :) This is fantastic. >=20 >> When you have time, feel free to go over it and critique what >> I've done. >=20 > I sure will do! How do you build that? Do I have to build whole > freebsd world or is there some easier way? Will "make" in = usr.bin/clang > work? On my FreeBSD 8 I first made lib/clang/libllvmsupport. After that I could make usr.bin/clang/tblgen and install it. Then it's easy: build lib/clang followed by usr.bin/clang. Install from usr.bin/clang Unfortunately, the FreeBSD build doesn't give me goodies like llc or bugpoint so there may be value in adding that to the FreeBSD build as optional or developer-only build targets... Thoughts anyone? >=20 >> My next steps are simple: Fix whatever blocks me from making >> progress: >>=20 >> ns1% cat ~/incr.c=20 >> int >> incr(int x) >> { >> return (x + 1); >> } >> ns1% clang -ccc-host-triple ia64 -S ~/incr.c=20 >> 'generic' is not a recognized processor for this target (ignoring = processor) >=20 > You can ignore this for now I think. I'll probably implement something simple like the merced and mckinley subtargets and default to mckinley. Later, when it's time to look at optimizations, is when this becomes important. >=20 >> error: unable to interface with target machine >> 1 error generated. >=20 > You have to create and register IA64InstPrinter. Check = MSP430/InstPrinter/* > and and MSP430AsmPrinter.cpp:createMSP430MCInstPrinter(). Ah, ok... BTW: these little tips save me hours of debugging. > I'll take some detailed looked in the evening! Thanks. Anytime, no rush... --=20 Marcel Moolenaar marcel@xcllnt.net