HOME

TheInfoList



OR:

ProGuard is an
open source Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
command-line tool that shrinks, optimizes and obfuscates
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
code. It is able to optimize
bytecode Bytecode (also called portable code or p-code) is a form of instruction set designed for efficient execution by a software interpreter. Unlike human-readable source code, bytecodes are compact numeric codes, constants, and references (norma ...
as well as detect and remove unused instructions. ProGuard is free software and is distributed under the
GNU General Public License The GNU General Public License (GNU GPL or simply GPL) is a series of widely used free software licenses that guarantee end user In product development, an end user (sometimes end-user) is a person who ultimately uses or is intended to ulti ...
, version 2. ProGuard was distributed as part of the Android SDK and ran when
building A building, or edifice, is an enclosed structure with a roof and walls standing more or less permanently in one place, such as a house or factory (although there's also portable buildings). Buildings come in a variety of sizes, shapes, and funct ...
the application in release mode.


Features

*
Bytecode Bytecode (also called portable code or p-code) is a form of instruction set designed for efficient execution by a software interpreter. Unlike human-readable source code, bytecodes are compact numeric codes, constants, and references (norma ...
-level optimizations; * Works with
Java Micro Edition Java Platform, Micro Edition or Java ME is a computing platform for development and deployment of portable code for embedded and mobile devices (micro-controllers, sensors, gateways, mobile phones, personal digital assistants, TV set-top ...
and Android;


Obfuscation

ProGuard obfuscates Java and Android programs by renaming classes, fields, and methods using meaningless names, making it harder to
reverse-engineer Reverse engineering (also known as backwards engineering or back engineering) is a process or method through which one attempts to understand through deductive reasoning how a previously made device, process, system, or piece of software accompli ...
the final application.


Optimization

Besides removing unused instructions from the compiled
bytecode Bytecode (also called portable code or p-code) is a form of instruction set designed for efficient execution by a software interpreter. Unlike human-readable source code, bytecodes are compact numeric codes, constants, and references (norma ...
, ProGuard optimizes it using techniques such as
control flow analysis In computer science, control-flow analysis (CFA) is a static-code-analysis technique for determining the control flow of a program. The control flow is expressed as a control-flow graph (CFG). For both functional programming languages and ob ...
,
data-flow analysis In computing, dataflow is a broad concept, which has various meanings depending on the application and context. In the context of software architecture, data flow relates to stream processing or reactive programming. Software architecture Dat ...
, partial evaluation, static single assignment,
global value numbering Value numbering is a technique of determining when two computations in a program are equivalent and eliminating one of them with a semantics-preserving optimization. Global value numbering Global value numbering (GVN) is a compiler optimization bas ...
, and liveness analysis. ProGuard can remove many types of unused and duplicated code, perform over 200 peephole optimizations, reduce variable allocation, inline constant and short methods, simplify
tail recursion In computer science, a tail call is a subroutine call performed as the final action of a procedure. If the target of a tail is the same subroutine, the subroutine is said to be tail recursive, which is a special case of direct recursion. Tail recur ...
calls, remove logging code, among others.


See also

*
Java (programming language) Java is a high-level, class-based, object-oriented programming language that is designed to have as few implementation dependencies as possible. It is a general-purpose programming language intended to let programmers ''write once, run an ...
*
Program optimization In computer science, program optimization, code optimization, or software optimization, is the process of modifying a software system to make some aspect of it work more algorithmic efficiency, efficiently or use fewer resources. In general, a co ...
*
Obfuscation (software) In software development, obfuscation is the act of creating source or machine code that is difficult for humans or computers to understand. Like obfuscation in natural language, it may use needlessly roundabout expressions to compose stateme ...
* Dotfuscator *
DashO (software) DashO is a code obfuscator, compactor, optimizer, watermarker, and encryptor for Java, Kotlin and Android applications. It aims to achieve little or no performance loss even as the code complexity increases. DashO can also statically analyze the ...


References

{{Reflist Software obfuscation Free software programmed in Java (programming language)