MIT's new tool automatically rewrites the old code for new software
But don't be afraid, there must be a man's hand to finish.
Writing computer software requires many cut-and-paste steps. It is also only part of the normal workflow - find a solution on Google, copy from Stack Overflow (or another source) and include it in the code. The final step will include some editing, rewriting, debugging.
Earlier this month, a team of scientists at MIT's CSAIL Lab revealed a new system that automatically puts code from one program to another.
The tool called CodeCarbonCopy (CCC) works by comparing the execution of the two software, then updating the variable name, representing the data with the source code. For example, if the original program called x, CodeCarbonCpy will find and replace the variables in the new code with the name x.
The work sounds normal but requires a basic understanding of what each software really does, as a variable makes sense in a certain context and how the software uses it.
Similar to data representation. This is a very interesting issue. CCC resolves by giving each software an input file and see what each will do. The result is a representative symbol of each value that the two software computes.
Transfer code from this software to another software automatically by CCC
In addition, CCC is also capable of detecting the functionality in the code used by the core software that the original software capital does not use.
The MIT team has experimented with 8 times of transcoding between 6 software, including VLC, mtPaint and MPlayer. During 7 transfers, the function is successfully kept during the transfer. At the 8th time from mtPaint to bmp2tiff, CCC cannot work because there are some strange data structures.
There is an anecdote that still communicates among developers about automation, that is, we will soon outsource to programming machines. CCC will not have good news then. But now rest assured that the system still needs human intervention.
People will have to determine the code to be transferred from the original program and the function to be transferred. CCC also takes a lot of time to work, the longest time when testing is 12 minutes.
You should read it
- Best programming application for iPad 2018
- Set of multiple choice questions on programming with P14 prize
- Standard color encoding for programmers and designers
- Multiple choice questions about programming with P1 prize
- 10 best programming games to test and develop your coding skills
- Share free programming bookstores for you to read restlessly
- Should we learn many programming languages or just one?
- 27 things I wish I knew before programming
- How to build a QR Code generator using React
- C ++ exercises have solutions (sample code)
- Learn Ruby programming from 0
- Test on JAVA test on P9
Maybe you are interested
What is addiction to social networks and how to solve this problem? How to cancel your virtual Facebook series in bulk The diving athlete's 24-minute record challenges the limits of science The secret to staying healthy and giving advice from experts Interesting discoveries about asteroids in the solar system What is gamma-ray burst?