Live data from Hacker News

Developer Preview – EC2 Instances with Programmable Hardware

aws.amazon.com

181–190 of 212 posts

Re: Developer Preview – EC2 Instances with Programmable Hardware

#181
post #68

Earlier quoted context omitted.

I would suggest Digital Design by Morris Mano[1]. It'll start off with basic intro from digital gates to FPGAs itself! And you really don't need any EE background for this book. This book starts from absolute basics and it'll also teach you Verilog along the way. And verilog is used more in the industry than VHDL(which more popular in Europe and in the US army for some reason). I'm surprised where you got the idea of…

I thought FPGA are programmed using low level languages like C

Not really. C is considered high level in digital design. There are some tools for high level synthesis, from languages like C but they aren't used much.

Most Fpga "programming" is a textual description of a directed graph of logic elements in a language like vhdl or Verizon (and now systemverilog).

Synthesis engines have gotten better over the years to allow things like +,* to decribe addition and multiplication instead of describing the logic graph of multiplication.

And most Fpgas now have larger built in primitives like 18x18 multipliers now.

You can judiciously use for-loops for repeated structures.

Re: Developer Preview – EC2 Instances with Programmable Hardware

#182

These FPGAs are absolutely _massive_ (in terms of available resources). AWS isn't messing around. To put things into practical perspective my company sells an FPGA based solution that applies our video enhancement technology in real-time to any video streams up to 1080p60 (our consumer product handles HDMI in and out). It's a world class algorithm with complex calculations, generating 3D information and saliency maps…

What can each one of those 2.5 million "logic elements" do? Last time I used an FPGA, they were mostly made up of 4-bit LUTs. How many NOT operations can this do per cycle (and per second)? I realise FPGAs aren't the most suited for this, but the raw number is useful when thinking about how much better the FPGA is compared to a GPU for simple ops.

The metrics have gotten pretty opaque since the old days when an FPGA was a "sea of LUTs" all alike; modern ones include a ton of (semi-)fixed function hardware like multiply-accumulate blocks and embedded dual-port RAM. Even the LUTs themselves can be reprogrammed into small RAM blocks or shift registers, so counting "logic elements" is mostly a marketing exercise.

Re: Developer Preview – EC2 Instances with Programmable Hardware

#183
post #161

Newbie question: What do verilog and VHDL compile down to, i.e. what is the assembly/machine language for FPGAs?

A logic-gate/register netlist, i.e. a digital schematic of your design. This is done by a synthesizer program. It is then mapped to the available resources of your chosen FPGA, by a mapping program. Now you have the logic equivalent schematic using the FPGAs resources. Then the netlist is place-and-routed to fit it into the FPGA. If the design is to large/complex or the timing requirements to strict (to high a clock frequency), this phase can fail. This phase can also take many hours to complete, even on fast computers.

Re: Developer Preview – EC2 Instances with Programmable Hardware

#184

These FPGAs are absolutely _massive_ (in terms of available resources). AWS isn't messing around. To put things into practical perspective my company sells an FPGA based solution that applies our video enhancement technology in real-time to any video streams up to 1080p60 (our consumer product handles HDMI in and out). It's a world class algorithm with complex calculations, generating 3D information and saliency maps…

Thank you so much for these posts, fpgaminer. They've been extremely helpful to me in framing how these things could be used.

Once upon a time I thought seriously about going in to hardware design. I took a couple different courses in college (over 10 years ago now... sigh) dealing with VHDL and/or verilog and entirely loved it. If not for a chance encounter with web programming during my co-op my career would have been entirely different. With AWS offering this in the cloud if it is not prohibitively expensive I'll be looking in to toying with it and hopefully discovering uses for it in my work.

Re: Developer Preview – EC2 Instances with Programmable Hardware

#185
post #170
post #129

Earlier quoted context omitted.

How do FPGAs compare with GPUs for the inference stage of Deep Learning algorithms? Can they accelerate it a lot?

No, but they do use less power: To the best of our knowledge, state-of-the-art performance for forward propagation of CNNs on FPGAs was achieved by a team at Microsoft. Ovtcharov et al. have reported a throughput of 134 images/second on the ImageNet 1K dataset [28], which amounts to roughly 3x the throughput of the next closest competitor, while operating at 25 W on a Stratix V D5 [30]. This performance is projected…

That's hard to compare. Typically FPGAs are doing fixed-point math, so they can do more operations with less power. GPUs have traditionally done floating point. However, with the new Pascal architecture, certain cards (P4/P40) support 8-bit integer dot products, which give a massive boost in performance/W. It's still fairly high at 250W, but that's for an entire card with 24GB of memory. You'd have to compare that to an FPGA with that much memory on a PCIe card if you're doing apples to apples. Something like this is appropriate for comparison: http://www.nallatech.com/store/fpga-accelerated-computing/pc...

Re: Developer Preview – EC2 Instances with Programmable Hardware

#186
post #123

I'm a total FPGA n00b, so here's a dumb question: what can you do with this FPGA that you can't with a GPU? OK, here's a concrete question: I have a vector of 64 floats. I want to multiply it with a matrix of size 64xN, where N is on the order of 1 billion. How fast can I do this multiplication, and find the top K elements of the resulting N-dimensional array?

FGPA = Field Programmable Gate Array. Basically, you can create a custom "CPU" for your particular workflow. Imagine the GPU didn't exist and you couldn't multiply vectors of floats in parallel on your CPU. You could use a FPGA to write something to multiply a vector of floats in parallel without developing a GPU. It would probably not be as fast as a GPU or the equivalent CPU, but it would be faster than doing it se…

Thanks. But what's the capacity of this particular FPGA? How much can it "do" ? Surely it can't emulate a dozen Xeons; so what's the upper bound on what can be done on this FPGA?

Re: Developer Preview – EC2 Instances with Programmable Hardware

#187

Earlier quoted context omitted.

I thought FPGA are programmed using low level languages like C

Not really. C is considered high level in digital design. There are some tools for high level synthesis, from languages like C but they aren't used much. Most Fpga "programming" is a textual description of a directed graph of logic elements in a language like vhdl or Verizon (and now systemverilog). Synthesis engines have gotten better over the years to allow things like +,* to decribe addition and multiplication ins…

verizon was meant to be verilog. didn't catch that autocorrect.

Re: Developer Preview – EC2 Instances with Programmable Hardware

#188
post #63

Earlier quoted context omitted.

Would this mean that the currency would never fluctuate below that price point?

It's a price ceiling, not a floor. If prices go up high enough, it's worth turning on EC2 instances and paying for them with the mined cryptocurrency until prices fall. There's some wiggle room above the break-even point, since there is some delay between turning on miners receiving USD, and the miner has to eat that risk.

Ah, yes, that makes sense, thank you!

Re: Developer Preview – EC2 Instances with Programmable Hardware

#189
post #65

For complex designs the simulator that comes with the Vivado tools (Mentor's modelsim) is not going to cut it. I wonder if they are working on deals with Mentor (or competitors Cadence and Synopsys) to license their full-featured simulators. Even better, maybe Amazon (and others getting into this space like Intel and Microsoft) will put their weight behind an open source VHDL/Verilog simulator. A few exist but they a…

As someone who has little experience with FPGAs beyond some experiments with a Spartan-6 dev board that mostly involved learning to write VHDL and building a minimal CPU, I found the simulator to be of limited use. My tiny projects were small enough that the education simulator was plenty fast. It was nice when I didn't have the board available, and occasionally, the logic analyzer was useful when I didn't understand what my code was doing to a data structure. But usually, it was just a lot easier to simply flash the board and run the thing.

What's the use of a simulator when you can spin up an AWS instance and run your program on a real FPGA?

Re: Developer Preview – EC2 Instances with Programmable Hardware

#190

Earlier quoted context omitted.

What can each one of those 2.5 million "logic elements" do? Last time I used an FPGA, they were mostly made up of 4-bit LUTs. How many NOT operations can this do per cycle (and per second)? I realise FPGAs aren't the most suited for this, but the raw number is useful when thinking about how much better the FPGA is compared to a GPU for simple ops.

The 2.5 million number quoted in the article is "System Logic Cells", not Logic Elements. Near as I can tell, since I haven't kept pace with Xilinx since their 7 series, a "System Logic Cell" is some strange fabricated metric which is arrived at by taking the number of LUTs in the device and multiplying by ~2. In other words, there is no such thing as a System Logic Cell, it's just a translucent number. Anyway, the F…

6-input, 1-output or 5-input, 2-output. They're implemented as a 5-input, 2-output LUT with a bypassable 2:1 mux on the output.
Post reply on HN