Implementing quantum algorithms on realistic hardware requires translating high-level global operations into sequences of native elementary gates, a process known as quantum compiling. Physical limitations, such as constraints in connectivity and gate alphabets, often result in unacceptable implementation costs. To enable successful near-term applications, it is crucial to optimize compilation by exploiting the potential capabilities of existing hardware. Here, we implement a resource-efficient construction for a quantum version of AND logic that can reduce the cost, enabling the execution of key quantum circuits. On a high-scalability superconducting quantum processor, we demonstrate low-depth synthesis of high-fidelity generalized Toffoli gates with up to 8 qubits and Grover's search algorithm in a search space of up to 64 entries; both are the largest such implementations in scale to date. Our experimental demonstration illustrates a scalable implementation of simplifying quantum algorithms, paving the way for larger, more meaningful quantum applications on noisy devices.