Posts Tagged ‘time’

Stop Saying "Lock Free Solution"

I am writing this at the airport, just coming back from the Intel IDF event. I keep hearing that we have “Lock Free” solutions for all sorts of problems. I think that this is a really bad choice of words. Let me try to explain why: My story starts with a friend who bought a sports car. That was a really good car with A very noisy engine. A new car like that is very expensive so he just got an old one. It worked fine but then one day as we drive to a party the car just stopped. We all went out popped the hood to look at the engine. Lovely engine. Shiny but it’s not running. We didn’t want to be late so eventually we found the solution. We all went to the back of the car and started pushing. I admit that it wasn’t going that fast but we got to the party. Later we found out that the car was out of gas. Two weeks later we went to see a movie and then again the car suddenly stopped working. Now we check the meter and it looks like the car has enough gas. So again we pop the hood and look at the engine. Eventually we find a solution. We all get behind the car and start pushing. We had a few problems up the hill so we went around it. Later we found out that this time it was the electrical system. The third time the car stopped working I told my friend that we need to find a “Push-Free” solution. I just thought that a “Push Free” solution would be more efficient. So now when we have car trouble we try to actually fix it… and we stopped calling it a Push Free solution. Now we just call it a fix. Sure, it is faster and simpler to just start pushing the car instead of really understanding the problem, and you know what, pushing the car can go around almost any problem that you may have. Locks can work around almost any problem that you may have. Just do me a favor and don’t call it a solution. When you solve a problem in your application don’t call it a “Lock-Free” solution… Let’s call it a solution. ** the friend in the story is as fictional as the need to use locks outside an infrastructure mechanism. Here is more: Locks Are Bad Here is me at the IDF event: Asaf Shelly Intel IDF Asaf

The Real Doctors of Fortran

In this blog, I refer to myself as “Doctor Fortran”.  It’s a joke that started more than ten years ago when I decided to write an “advice column” for what was then the Digital Visual Fortran Newsletter.  Everyone liked it so much I stuck with it, but I’ve always been aware of the people who deserve that title far more than I – the members of the Fortran standards committee.  As it happens, I am an “alternate” member of the committee representing Intel, but most of the time we are represented by Stan Whitlock.  Intel Fortran developer Lorri Menard is our other alternate member.  I’ve now attended three standards meetings and thought I’d write up my experience of the most recent and give readers a feel for how the Fortran language’s evolution is guided and its cohesiveness maintained. First, some background.  There is the International Standards Organization (ISO) Fortran committee whose full designation is ISO/IEC/JTC1/SC22/WG5 .  We’ll call that WG5 for short. WG5 has members from around the world – its charter is to establish the direction for the Fortran standard: at a high level, which features should it have?  WG5 also has the final approval on a new standard, with each member country having one vote. WG5 meets once a year at a location that shifts among various member host countries. WG5 doesn’t do the nuts-and-bolts work of developing the standard – that task is assigned to the US Fortran standards committee, a subset of WG5.  Formally called INCITS PL22.3, members typically refer to it as J3 , a term dating back to the American National Standards Institute (ANSI) X3J3 committee. J3 has representatives from vendors (Cray, IBM, Intel, NAG, Oracle) and users (universities, national labs and individuals.)  The J3 meetings, held three times a year, are also regularly attended by voting alternates from inside and outside the US, including Toon Moene of the gfortran project. One of the three yearly J3 meetings is held coincident with the yearly WG5 meeting. It was my honor to be Intel’s representative at the June 2011 joint WG5/J3 meeting, held in Garching, Germany, a pleasant suburb of Munich, at the LRZ Supercomputing Center (LRZ stands for Leibniz-Rechenzentrum or Leibniz Research Center.)  The Fortran 2008 standard had been approved the previous October, so you might think we didn’t have much to do, but the week was full. No, we were not starting to design the features for the next Fortran standard – in fact, it was generally agreed that wouldn’t happen for another year or two, and WG5 still needed to come up with the general direction for the next standard.  Many members of J3 and WG5, including myself, are of the opinion that the next standard should be a “corrections and clarifications” version with few or no new features so that vendors and users have a chance to “catch up”. The biggest work item was TS 29113 on Enhanced C Interoperability. In standards speak, TS means Technical Specification and in this case is used when there is a language feature whose design is not complete in time for standards approval but is firm enough to encourage vendors to implement it.  (In the past, this was called TR for Technical Report.)  Typically, when a TS has been approved it is agreed that it will be incorporated in the next standard as-is, minimizing risk to vendors and users. The most well-known use of a TS in the past was the one that brought us allocatable components of derived types, incorporated into Fortran 2003. TS 29113, or “the Interop TS”, wants to extend the C interoperability features of Fortran in two main ways: Allow C procedures to be passed assumed-shape, pointer and allocatable variables and to give C programmers the means to read, write, and reallocate such arguments, and also to allow C to define such variables and pass them to Fortran Provide support for interoperability with a C “void *” argument that has no explicit type or shape The TS underwent significant changes during the week, but the fundamental ideas remained: The concept of “assumed type”, designated by TYPE(*), and “assumed rank”, designated by DIMENSION(..).  Think of the .. as a colon on its side – DIMENSION(*) already has a meaning in Fortran The notion of a “C descriptor” with a known structure, and a C header file that declares the structure and functions C code can call to manipulate these descriptors. For more details on the Interop TS, you can read the current TS 29113 draft (PDF). The other major task that occupied us was interpretations.  These are submitted by users and vendors when they think there is an ambiguity in the standard or they want to know if a particular meaning was intended by the committee.  There was quite a backlog of these, as development of F2008 had taken up a lot of time, but we knocked off a lot of them. I remember one I worked on which asked if parameterized derived types could have the SEQUENCE attribute, as if they could, this greatly complicated the process of determining when two derived type declarations were “the same”.  (We concluded that it made no sense to allow parameterized derived types to be SEQUENCE types.)  Another interpretation lifted the restriction that the arguments to C_LOC and C_F_POINTER be interoperable, greatly increasing their usability. The process works this way.  One or more members takes an interpretation request and, if necessary, rewrites it to refer to the current standard, since many were submitted against Fortran 2003.  An answer is proposed – it may be that the standard is correct as-is and no change is required, or a wording change is proposed.  The answer is then voted on by the members present.  Sometimes there are objections and another revision is made.  If the interpretation is approved, it then goes on a letter ballot submitted to all J3 members, who can approve, approve with comments, or reject (with comments).  Lastly, a ballot of WG5 members is done. Only if the interpretation passes this third round is it considered part of the standard, and later included in a set of edits called a corrigendum. As a break from working on the standard, we got a tour of LRZ’s immense building housing its multiple supercomputer clusters.  Photographs were not allowed in here, but I was impressed by the extensive and elaborate lightning and fire suppression systems.  Later in the week we also got a tour of the Munich Computer Museum, with working examples of many significant computers from the past.  You can view a gallery of the photos I took here .  And then there was the atrium of the LRZ building where we ate lunch.  It features two giant tube slides that go from the fourth floor down to the first.  Blankets were provided if you wanted to try it out, but I didn’t see anyone do so while I was there. Each time I have attended a standards meeting, I have been impressed with the members’ dedication to the Fortran language.  While there are a variety of personalities on the committee, they all work together to make Fortran the best it can be.  I’m glad to have been a small part of this effort and look forward to future opportunities to participate in Fortran’s future.

Let’s rename "for" to "serial_for"…

Proposal: rename  for in C and C++ to serial_for No more incumbent “for.” (it was voted off the island) (let’s assume parallel_for == cilk_for in this discussion) Consider: serial_for (i=0; i < n; i++) { body } vs. parallel_for (int i=0; i < n; i++) { body } serial_for allows the values of n and i to be modified inside body , parallel_for does not serial_for allows body of one iteration to affect body of a future iteration, parallel_for does not serial_for guarantees the exit value of i will be n, parallel_for does not That’s the highlights. Which should we use?  serial_for or parallel_for ? What if I told you that every new computer today can reasonably be expected to work better with parallel_for than serial_for … and the difference will keep getting bigger in the future? “Serial Traps” has been a topic between myself and two co-authors for an upcoming book on parallel programming. I think we are coining phrase… and maybe this is the first coin off the presses.  Maybe someone else already coined it and we didn’t know it?  It’s hardly a new idea… but we constantly get reminder that it is not widely understood. I am developing a list of “Serial Traps” which are use of a programming method, that has unintended consequences on parallel program performance.  for as a serialization method – is one such trap. I say “unintended” because I do believe large numbers, if not most, for loops are not written to depend on the features of serial_for that are not supported by parallel_for . My favorite short example: for (int i=0;i

Coollector Movie Database 2.99.29

If you like movies, you´ll love Coollector Movie Database. And if you own some DVD, you´ll love it even more. Browse its huge database of movies and series, with its gorgeous interface and unmatched search engine. Rate all the movies that you´ve seen, to remember whether they were good, or just a waste of your time. Decide the next movies you´ll watch, by getting a clue from their IMDb rating and popularity, by checking if they have a director and actors that you like, and by watching the trailers on Youtube. Maintain a wishlist. Manage your video collection, remember what you own, where it´s stored, and what you loaned to whom. Automatically scan the video files on your hard drive, to play them conveniently from the program. Thanks to the integrated shopping helpers, don´t miss a bargain, and grow your collection at the best price. Other noteworthy features: direct links to the IMDb, list printing, Cooliris 3D wall, coollection sharing with your friends. What´s New in version 2.99.29: [NEW] added 300 movies & series Homepage : http://www.coollector.com/ Download : Coollector_Setup.exe File Size : 36.56MB

H2 Database Engine 1.3.158

H2 is an SQL database engine written in Java (but also available as a native binary). Features: It is free to use for everybody, source code is included Written in Java, but also available as native executable JDBC and (partial) ODBC API Embedded and client/server modes Clustering is supported A web client is included Fast database engine Free, source code is included Supports standard SQL Disk based or in-memory databases Browser base Console application Wide range of data types including large objects (BLOB/CLOB) Strong security features (SSL, users, roles, encrypted files) Multiple connections, table level locking Cost based optimizer, using a genetic algorithm for complex queries Transaction support (serializable transaction isolation) Zero-administration, automatic recovery Large resultset, external sorting Scrollable and updatable resultset support Read only views and inline views Inner and outer joins, subqueries Many functions already built-in Compatibility modes for HSQLDB, MySQL and PostgreSQL Small footprint (smaller than 1 MB) Uses a small number of database files Can be compiled to native code using GCJ Primary keys, multiple index types (b-tree, linear hash, tree, hash) ORDER BY, GROUP BY, HAVING, UNION, LIMIT The database can generate SQL script files Support for linked tables, and a built-in virtual ´range´ table Automatic re-compilation of prepared statements Sophisticated trace options Low memory requirements Standard handling of NULL values Multilanguage console application (at this time, English and German) Much more Homepage : http://www.h2database.com/ Download : h2-setup-2011-07-17.exe File Size : 3.83MB

VisiTimer

VisiTimer is a countdown timer that provides a visual representation of the time remaining as it counts down in the form a radial sweep that paints an image or shape progressively in synch with the time as it passes. Time is up when the image or shape is completely visible. This is excellent for…

Gaming in Transition and Revolution: Pt 4 of 4

Part 4 of 4 (Innovation Changers) This will be my final installment on this blog topic titled: Gaming – in transition and revolution. To briefly recap the previous topics I first talked about the impact of Mobile. In my second installment I covered the changes and evolutions occurring in both formats and business models. In the last blog I covered globalization and some of those impacts. For purposes of today’s discussion I’ll talk about what I believe are going to be the biggest Innovation changers from a gaming perspective. There are really three standouts for me. Gesture Computing: Let’s get the most obvious one out of the way first. While gesture computing and devices have existed for quite some time as ‘science-experiments’, this particular innovation didn’t really get mainstream traction until the advent of the Wii-Motion Controller. Microsoft of course escalated this and took it to a whole new level by having no input device other than the user themselves for the Kinect on Xbox 360. The result is now we have PC-like devices (Console/s, soon Windows PC’s) that recognize human gestures. Microsoft did a smart thing by releasing an SDK for the Kinect allowing others to create innovative gesture based interactive applications. I believe they realized that keeping it solely in the domain of the Xbox would have been far too limiting; and it proved to be far too juicy of a target for hackers which is the last thing any Console can afford to have happen. The trend derived from all this is that humans now have additional options for interacting with devices. In the grand scheme of it all for gaming I really believe that what this gets us closer to is what I call ‘Sensory Computing’. This will tie Gesture, Voice, Touch, and ultimately Artificial Intelligence (AI) altogether. Wireless: The second big innovation changer may not sound so interesting or sexy by comparison but I feel is just as important are the advancements taking place for Wireless Technologies. While this has been around now for quite some time the improvements are no less astounding. In thinking back to the days of ‘dial-up modems’ in the 90’s with 28-56 baud rates to what we have access to today with things like gigabit wireless routers and WHDI (Wireless Home Digital Interface) one has to wonder what the next five, ten, or twenty years are going to look like? From a gamers perspective I’m still a big stickler for any perceivable latency rates. However; things are getting to the point now where most of the time it’s no longer an issue when I’m playing my online or multi-player games across a WiFi network. Being able to view my entertainment experiences such as Games, Movies, etc interactively and seamlessly between all the devices I own is an interesting prospect indeed but has some very deep implications from a Content Designer, and Platform owners perspective. In that world proprietary will actually be a huge detriment. Web Graphics: The third and final biggest innovation changer occurring right now is that of Web Graphics. I’m keeping a very close eye on the advancements taking place in browsers such as Google Chrome, FireFox, and Internet Explorer. The graphics capabilities of things like WebGL, HTML 5.0, or even Silverlight have come a very long way very rapidly and in my opinion are fast closing the gap on DirectX 9 level of graphics prettiness. These graphics stacks are also tapping into the power of GPUs further intensifying and accelerating Web Graphics capabilities. Tying this back to the implications for gaming or any entertainment scenario involving graphics is huge. Most notably it comes down to the features and visual acuity of what these graphics stacks can deliver across a browser. Since even most 1st person shooter style games have been dumbed-and-slowed-down for Console style gamepads there are really no games left that theoretically couldn’t be taken to a browser. The implications and cause and effect are enormous to the Gaming Industry. For starters the game can now be delivered across anything that has a capable browser. Mileage will of course vary based on the hardware and screen present. However; the cool thing is now the Developer/Publisher of the game has access to ~10x or more the number of potential consumers. Even better the game is no longer chained to one particular platform or another. (Bye Bye Consoles…. Bye Bye…..) So there you have it. What I believe are going to be the three biggest game changers and disruptors for gaming in the near to long term. 1. Gesture Computing being a precursor to a more immersive Sensory Computing experience 2. Wireless continuing to break the chains 3. Web Graphics, as it evolves, forever altering the landscape for how we access and consume games. What does it all mean? What’s the purpose of this four part blog? What are the key points I’m trying to make? Let me close with this. What I touched on in these four blog posts is seriously only the tip of the iceberg. I also feel its imperative that companies step back and look at what I discussed as holistically as possible and what the ramifications are long term. The most salient part about all this is that the big 4 trends that I touched on don’t happen independently of each other. They all happen simultaneously. So my personal advice is as follows: 1. Start with Mobile as the standard platform and fan out from there to other devices. To be crystal clear that is Smart/iPhones for something that fits in your hand, and thin and light laptops. Tablets/Slates are nothing more than a distraction in my opinion since they’ll morph and transform into being another iteration of a thin and light laptop anyway. 2. To deliver content consider free to play and digital distribution as key options; and steer away from exclusives. Out of the gate you want to be able to hit as many consumers as you can. (That or ask for far more money than you do for an exclusive) 3. Consider globalization not as something scary; but something to embrace as a means by which to grow the pie considerably. Think globally and in terms of what the rest of the worlds disposable income rates are. (You’d be hard pressed to hit a billion users otherwise) 4. Innovation-wise I believe the real big game changers are typically those that take years to evolve. Don’t get too distracted with bright shiny objects. Long term the open, or smartly managed primarily-open platforms have the best chances of survival due their inherent flexibility. So that concludes this blog as I go into my 4th of July weekend. I’m sure there are some gross generalities or oversights on my part. (I’m human!) I hope you enjoyed reading this blog. I hope you all have a great weekend. If you have other thoughts or insights to add by all means please comment! – Matt

Google celebrates Father’s Day

Google has a knack for celebrating special days. This time around, they have managed to celebrate Father’s Day in its own special way. They have designed a new Google Doodle for this special day. It has designed an embossed tie motif to wish “Dads” across the globe a Happy Father’s Day. They had managed a similar design for “Mother’s Day” as well. After their interactive Guitar Doodle as a mark of respect for the Late Les Paul, this dedication for “Father’s Day” wasn’t as interesting but was definitely elegant and simple. Google has always used the “neck-tie” as a symbol for this day. Google fans believe that the site goes an extra mile to make them feel special and happy about these simple special days. They certainly aren’t disappointed.

Twitter to offer automated ad buying system

Twitter has now decided to offer an automated system for buying ads for small businesses. Predictably, this would lead to a torrent of new advertising in the business market. Twitter’s president of global revenue- Adam Bain feels that Twitter’s sales department does not have the time to go through each and every demand of the small businesses that approach them. Thus Twitter has decided to offer a ready made/ turnkey type of ads by the end of this year. In 2010, Twitter had come out with a online form and a program that helped marketeers promote themselves through tweets, trends and accounts. Marketeers could also find leads for the twitter market reps. If implemented, apart from raising prices for ads in Google AdWords, it would also increase Twitter’s revenue from advertising to $150 million, almost the same as that of Facebook’s ad revenue in 2007.

Gmail Spear Phishing Attack May Affect Hotmail, Yahoo Mail – CRN

MSN Philippines News Gmail Spear Phishing Attack May Affect Hotmail, Yahoo Mail CRN Security researchers say that a Gmail spear phishing attack targeting high-profile users might have spread to Hotmail and Yahoo Mail services, while it remains uncertain if the attack, originating from China, … Hotmail, Yahoo Mail users also targets in attacks msnbc.com Report: Gmail Attacks Replicated on Hotmail, Yahoo PC Magazine Security Boffins Smell Phish in Hotmail, Yahoo TechNewsWorld AFP